RE: Localization , French Accents...
Thanks Paul! -Original Message- From: Paul Hastings [mailto:p...@sustainablegis.com] Sent: February-27-13 5:31 PM To: cf-talk Subject: Re: Localization , French Accents... On 2/28/2013 3:05 AM, Brook Davies wrote: Sorry, Unicode/utf-8 are the same thing...my mistake.. they're not the same thing. unicode is a *standard* (the unicode consortium produces a book the unicode standard). utf-8 (UCS Transformation Format 8 bit) is one *encoding* implementing that standard, there are others. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:354737 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Localization , French Accents...
Not sure if this helps and depends what you're trying to do with the text, if you want to output them to a page, putting this at the top of the .cfm page should help. cfprocessingdirective pageEncoding = utf-8 I had problems displaying foreign characters until I included the above on the pages. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:354708 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Localization , French Accents...
My first guess is that it is happening when the file is read in. Was it saved as unicode? I think notepad lets you do that. If not, notepad++ does. On 2/27/13 12:52 PM, Brook Davies cft...@logiforms.com wrote: I am trying to read in a number of text files that contain translations (using French in this example) and store them in my applications app scope. The file I am reading in looks like this: http://screencast.com/t/DZTv3iVrbyo When I dump the results from reading in the file, or try to use them in output, the accents get munged: http://screencast.com/t/aoRcLWWHn I have tried everything I can think of to get this to work and everything has failed. I have tried manually setting the charset on the CFFILE tag and that has not helped. I tried using UTF-8, and WINDOWS-1255. Since I have numerous language files I have even tried implementing this java class org.mozilla.universalchardet.UniversalDetector that detects the encoding of a file, and then using the detected encoding when reading in the translation files. But no matter what I do, the encoding is not preserved. Note, this library tells me my French files are WINDOWS-1255./ Does anyone have any suggestions on how I can handle this? Brook ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:354709 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: Localization , French Accents...
Should I be saving it in Unicode or UTF-8? -Original Message- From: Bobby [mailto:bo...@acoderslife.com] Sent: February-27-13 11:01 AM To: cf-talk Subject: Re: Localization , French Accents... My first guess is that it is happening when the file is read in. Was it saved as unicode? I think notepad lets you do that. If not, notepad++ does. On 2/27/13 12:52 PM, Brook Davies cft...@logiforms.com wrote: I am trying to read in a number of text files that contain translations (using French in this example) and store them in my applications app scope. The file I am reading in looks like this: http://screencast.com/t/DZTv3iVrbyo When I dump the results from reading in the file, or try to use them in output, the accents get munged: http://screencast.com/t/aoRcLWWHn I have tried everything I can think of to get this to work and everything has failed. I have tried manually setting the charset on the CFFILE tag and that has not helped. I tried using UTF-8, and WINDOWS-1255. Since I have numerous language files I have even tried implementing this java class org.mozilla.universalchardet.UniversalDetector that detects the encoding of a file, and then using the detected encoding when reading in the translation files. But no matter what I do, the encoding is not preserved. Note, this library tells me my French files are WINDOWS-1255./ Does anyone have any suggestions on how I can handle this? Brook ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:354714 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Localization , French Accents...
UTF-8 should do it. On 2/27/13 3:00 PM, Brook Davies cft...@logiforms.com wrote: Should I be saving it in Unicode or UTF-8? -Original Message- From: Bobby [mailto:bo...@acoderslife.com] Sent: February-27-13 11:01 AM To: cf-talk Subject: Re: Localization , French Accents... My first guess is that it is happening when the file is read in. Was it saved as unicode? I think notepad lets you do that. If not, notepad++ does. On 2/27/13 12:52 PM, Brook Davies cft...@logiforms.com wrote: I am trying to read in a number of text files that contain translations (using French in this example) and store them in my applications app scope. The file I am reading in looks like this: http://screencast.com/t/DZTv3iVrbyo When I dump the results from reading in the file, or try to use them in output, the accents get munged: http://screencast.com/t/aoRcLWWHn I have tried everything I can think of to get this to work and everything has failed. I have tried manually setting the charset on the CFFILE tag and that has not helped. I tried using UTF-8, and WINDOWS-1255. Since I have numerous language files I have even tried implementing this java class org.mozilla.universalchardet.UniversalDetector that detects the encoding of a file, and then using the detected encoding when reading in the translation files. But no matter what I do, the encoding is not preserved. Note, this library tells me my French files are WINDOWS-1255./ Does anyone have any suggestions on how I can handle this? Brook ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:354715 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: Localization , French Accents...
Sorry, Unicode/utf-8 are the same thing...my mistake.. -Original Message- From: Bobby [mailto:bo...@acoderslife.com] Sent: February-27-13 11:01 AM To: cf-talk Subject: Re: Localization , French Accents... My first guess is that it is happening when the file is read in. Was it saved as unicode? I think notepad lets you do that. If not, notepad++ does. On 2/27/13 12:52 PM, Brook Davies cft...@logiforms.com wrote: I am trying to read in a number of text files that contain translations (using French in this example) and store them in my applications app scope. The file I am reading in looks like this: http://screencast.com/t/DZTv3iVrbyo When I dump the results from reading in the file, or try to use them in output, the accents get munged: http://screencast.com/t/aoRcLWWHn I have tried everything I can think of to get this to work and everything has failed. I have tried manually setting the charset on the CFFILE tag and that has not helped. I tried using UTF-8, and WINDOWS-1255. Since I have numerous language files I have even tried implementing this java class org.mozilla.universalchardet.UniversalDetector that detects the encoding of a file, and then using the detected encoding when reading in the translation files. But no matter what I do, the encoding is not preserved. Note, this library tells me my French files are WINDOWS-1255./ Does anyone have any suggestions on how I can handle this? Brook ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:354716 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
RE: Localization , French Accents...
Bobby, thanks for the notepad+ idea - it was the encoding on the source file -Original Message- From: Bobby [mailto:bo...@acoderslife.com] Sent: February-27-13 12:05 PM To: cf-talk Subject: Re: Localization , French Accents... UTF-8 should do it. On 2/27/13 3:00 PM, Brook Davies cft...@logiforms.com wrote: Should I be saving it in Unicode or UTF-8? -Original Message- From: Bobby [mailto:bo...@acoderslife.com] Sent: February-27-13 11:01 AM To: cf-talk Subject: Re: Localization , French Accents... My first guess is that it is happening when the file is read in. Was it saved as unicode? I think notepad lets you do that. If not, notepad++ does. On 2/27/13 12:52 PM, Brook Davies cft...@logiforms.com wrote: I am trying to read in a number of text files that contain translations (using French in this example) and store them in my applications app scope. The file I am reading in looks like this: http://screencast.com/t/DZTv3iVrbyo When I dump the results from reading in the file, or try to use them in output, the accents get munged: http://screencast.com/t/aoRcLWWHn I have tried everything I can think of to get this to work and everything has failed. I have tried manually setting the charset on the CFFILE tag and that has not helped. I tried using UTF-8, and WINDOWS-1255. Since I have numerous language files I have even tried implementing this java class org.mozilla.universalchardet.UniversalDetector that detects the encoding of a file, and then using the detected encoding when reading in the translation files. But no matter what I do, the encoding is not preserved. Note, this library tells me my French files are WINDOWS-1255./ Does anyone have any suggestions on how I can handle this? Brook ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:354721 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Localization , French Accents...
Any time. Glad it's worked out. On 2/27/13 3:56 PM, Brook Davies cft...@logiforms.com wrote: Bobby, thanks for the notepad+ idea - it was the encoding on the source file -Original Message- From: Bobby [mailto:bo...@acoderslife.com] Sent: February-27-13 12:05 PM To: cf-talk Subject: Re: Localization , French Accents... UTF-8 should do it. On 2/27/13 3:00 PM, Brook Davies cft...@logiforms.com wrote: Should I be saving it in Unicode or UTF-8? -Original Message- From: Bobby [mailto:bo...@acoderslife.com] Sent: February-27-13 11:01 AM To: cf-talk Subject: Re: Localization , French Accents... My first guess is that it is happening when the file is read in. Was it saved as unicode? I think notepad lets you do that. If not, notepad++ does. On 2/27/13 12:52 PM, Brook Davies cft...@logiforms.com wrote: I am trying to read in a number of text files that contain translations (using French in this example) and store them in my applications app scope. The file I am reading in looks like this: http://screencast.com/t/DZTv3iVrbyo When I dump the results from reading in the file, or try to use them in output, the accents get munged: http://screencast.com/t/aoRcLWWHn I have tried everything I can think of to get this to work and everything has failed. I have tried manually setting the charset on the CFFILE tag and that has not helped. I tried using UTF-8, and WINDOWS-1255. Since I have numerous language files I have even tried implementing this java class org.mozilla.universalchardet.UniversalDetector that detects the encoding of a file, and then using the detected encoding when reading in the translation files. But no matter what I do, the encoding is not preserved. Note, this library tells me my French files are WINDOWS-1255./ Does anyone have any suggestions on how I can handle this? Brook ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:354722 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Localization , French Accents...
On 2/28/2013 3:05 AM, Brook Davies wrote: Sorry, Unicode/utf-8 are the same thing...my mistake.. they're not the same thing. unicode is a *standard* (the unicode consortium produces a book the unicode standard). utf-8 (UCS Transformation Format 8 bit) is one *encoding* implementing that standard, there are others. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:354726 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm
Re: Localization , French Accents...
Just a note on this: the cfprocessingdirective tag used in this way simply tells the CF compiler to treat *that file* as UTF-8 when it's compiled. IE: if the file itself has UTF-8-encoded text within it, the compiler will respect that when the CFML is compiled. It has no bearing at all on displaying or reading UTF-8 encoded data (which are only relevant at runtime, not compile time). -- Adam On 27 February 2013 18:52, Akos Fortagh akos.fort...@yahoo.com wrote: Not sure if this helps and depends what you're trying to do with the text, if you want to output them to a page, putting this at the top of the .cfm page should help. cfprocessingdirective pageEncoding = utf-8 I had problems displaying foreign characters until I included the above on the pages. ~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:354729 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm