Thank you all !
Finally, thanks to the last tip from Jonathan I added  
*ini_set('default_charset', 'utf-8');*  instead of  
ini_set('default_charset', '');  and now it is working well !!!
Thank you very much!



Jonathan Snook wrote:
> I think it'd be more appropriate to be explicit:
>
> ini_set('default_charset', 'utf-8');
>
> Alternatively, you can set the charset manually using:
> header('Content-type: text/html; charset="utf-8"');
>
> -Jonathan
>
> On Tue, Jun 10, 2008 at 1:34 PM, Pierre MARCOURT
> <[EMAIL PROTECTED]> wrote:
>   
>> Thanks Marcin,
>>
>> I am still having this problem.
>> I tried what you say but it is the same.
>> I did the comment, and I also add the line in the bootstrap.php but it does
>> not work.
>> I don't get it...
>>
>>
>> Marcin Jaworski wrote:
>>
>> The problem with UTF-8 is that you can't autodetect that the file is
>> using this charset until you use characters from outside the ascii
>> range. UTF-8 uses 1-byte encoding for this range and it isn't much
>> different from ISO then. When you use some characters from outside of
>> ASCII charset then UTF-8 encodes those characters using two bytes. If
>> you use files without BOM, then the only way to detect if file is
>> UTF-8 encoded is to check if it contains any 2-byte encoded
>> characted.
>>
>> Dreamweaver does that exactly in the same way. You probably don't have
>> any 2-byte character in your source so DW won't detect the file as
>> UTF-8. Do the test: put a comment inside some php file and place some
>> non-ascii characters in it. For example (at the end are some polish
>> characters, hope you will see them):
>> // this is a test ąśćżźó
>>
>> Save the file with this comment as UTF-8, send it to the server and
>> then try to open it with DW. You will see that it will open as UTF-8.
>>
>> About the page encoding problem: you don't need to edit any server
>> configuration file. Open app/config/bootstrap.php file and add at the
>> end:
>> ini_set('default_charset', '');
>>
>> This should do the trick.
>>
>> On 10 Cze, 17:37, Pierre MARCOURT <[EMAIL PROTECTED]> wrote:
>>
>>
>> I double checked and I noticed something strange.
>> If I set the character encoding to UTF-8 without BOM via an editor and
>> then I upload it on the remote server, when I download the same file
>> from the remote server and open it with the same editor, the character
>> encoding of this file is not UTF-8 anymore but ISO.
>> I checked that because I don't have any trouble about character encoding
>> on local, and this problem happened when I uploaded all my project on a
>> remote server.
>>
>> I have to set up cakephp in a particular folder, let's say /cake/
>> So you can find my project athttp://www.my-web-site.com/cake/
>> The rest of the websitehttp://www.my-web-site.comis encoding with
>> Western (ISO).
>> Could it be the source of my trouble ? Is this a problem regarding the
>> configuration of PHP ?
>> The thing is, I don't have access to any files, I am just allow to work
>> in my /cake/ folder...
>>
>>
>>
>> Marcin Jaworski wrote:
>>
>>
>>
>> On 10 Cze, 16:23, Pierre MARCOURT <[EMAIL PROTECTED]> wrote:
>>
>>
>> Hi,
>>
>>
>> I have just uploaded my CakePHP project on a remote server but I meet an
>> issue.
>> In all my views, I get the text "  " on the top.
>> I know this is a problem (on FF) regarding to the character encoding
>> (cf.http://groups.google.com/group/cake-php/browse_thread/thread/28f129e2...)
>> but in local, I don't have this problem !
>> Moreover, in my default.thtml layout I set the character encoding thanks
>> to : <?php echo $html->charsetTag('UTF-8')."\n"; ?>
>> If I look at the source code, I have the meta UTF-8 defined.
>> But if I check the character encoding of my FF browser, it is : Western
>> (ISO-8859-1).
>> Plus, it is working well on IE 7 and Safari 3.1.1.
>> Finally in my editor : Dreamweaver (Sorry,
>> cfhttp://groups.google.ch/group/cake-php/browse_thread/thread/392484f52...)
>> I have set up character encoding at UTF-8 without BOMs.
>>
>>
>> Please help me because I don't have more idea to fix this.
>>
>>
>> Regards,
>>
>>
>> The problem with page charset is because PHP sends HTTP Header
>> "Content-Type: text/html; charset=iso-8859-1". You could try and
>> override the default_charset php ini parameter by calling this as
>> early as possible:
>>
>>
>> ini_set('default_charset', '');
>>
>>
>> This will clear the default charset setting in php and allow to set
>> the charset by http equiv tag in page header.
>>
>>
>> --
>>  *Pierre MARCOURT*
>>
>> *IT Department*
>>         *CableOrganizer.com*
>> 5610 NW 12th Ave, suite 214
>> Fort Lauderdale, FL 33304
>>
>>         Phone: 954-861-6310
>> Fax: 954-861-2001
>>
>>
>>
>>
>> --
>>  Pierre MARCOURT
>>
>> IT Department
>> CableOrganizer.com
>> 5610 NW 12th Ave, suite 214
>> Fort Lauderdale, FL 33304
>>
>>
>> Phone: 954-861-6310
>> Fax: 954-861-2001
>>     
>
> >
>
>   


-- 
 *Pierre MARCOURT*      
         
*IT Department*         
        *CableOrganizer.com*
5610 NW 12th Ave, suite 214
Fort Lauderdale, FL 33304
 

        
        Phone: 954-861-6310
Fax: 954-861-2001


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to