Re: [PHP] Latin letter problem!
On 20/02/07, Richard Lynch <[EMAIL PROTECTED]> wrote: PS Mozilla-based browsers want your charset in the HTTP Content-type header IE and IE-knockoff browsers want your charset in the META tags. You have to do *both* to get all browsers to play nicely. Even for mozilla-based browsers you need the meta tag, as pages stored on disk do not contain the http header. So if the user is using scrapbook, or simply storing the pages on his hard drive, he will need the meta tag. Dotan Cohen http://essentialinux.com/tips.php http://faq-google.com -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Latin letter problem!
PS Mozilla-based browsers want your charset in the HTTP Content-type header IE and IE-knockoff browsers want your charset in the META tags. You have to do *both* to get all browsers to play nicely. Sorry. On Tue, February 20, 2007 10:03 am, Delta Storm wrote: > Hi, > > I'm building an simple CMS system. I have built almost everything but > one thing buggs me... > > I have a MySQL database built for publishing news > (Id,title,newsContent,timestamp). > > And I have a php web page that displays that content. The problem is > with the charset, in the database the settings are following: > > character set latin2 collation latin2_croatian_ci; > > and in the tables character set utf8; > > I display the data in the php page using utf8 I see all the non-PHP > content pure HTML content capable of seeing croatian letter > ÄÄžšÄ, but > in the news section I only see ÄÄÄ. But they are on the same page! > > I tried putting other HTML charsets like iso-8859-1,iso-8859-2 etc... > But in all the scenarios I get the HTMl part working but PHP not > working > vice-versa... > > > Please help me it is a very important web page if you need any other > information just ask! > > Thank you very much in advance! > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- Some people have a "gift" link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Latin letter problem!
I believe you want to send a query something like: mysql_query("SET CHARACTER SET 'utf-8'"); to convince PHP / MySQL client/server interaction to also be in UTF-8, on top of the internal storage engine storing things in UTF-8. More info about this SET stuff is at: http://dev.mysql.com/ I found the way to get PHP/MySQL to tell me what it was using, and mine was already in UTF-8, so I didn't actually get as far as trying it. :-v On Tue, February 20, 2007 10:03 am, Delta Storm wrote: > Hi, > > I'm building an simple CMS system. I have built almost everything but > one thing buggs me... > > I have a MySQL database built for publishing news > (Id,title,newsContent,timestamp). > > And I have a php web page that displays that content. The problem is > with the charset, in the database the settings are following: > > character set latin2 collation latin2_croatian_ci; > > and in the tables character set utf8; > > I display the data in the php page using utf8 I see all the non-PHP > content pure HTML content capable of seeing croatian letter > ÄÄžšÄ, but > in the news section I only see ÄÄÄ. But they are on the same page! > > I tried putting other HTML charsets like iso-8859-1,iso-8859-2 etc... > But in all the scenarios I get the HTMl part working but PHP not > working > vice-versa... > > > Please help me it is a very important web page if you need any other > information just ask! > > Thank you very much in advance! > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, visit: http://www.php.net/unsub.php > > -- Some people have a "gift" link here. Know what I want? I want you to buy a CD from some starving artist. http://cdbaby.com/browse/from/lynch Yeah, I get a buck. So? -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Latin letter problem!
On 20/02/07, Peter Lauri <[EMAIL PROTECTED]> wrote: How are you setting the charset of the web page? Are you using header() or using html head section to set it? First, the header() function. Then again in the tag, and a final time in the meta tag. This way cached pages and pages stored on disk will display properly as well. http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd";> http://www.w3.org/1999/xhtml"; xml:lang="he" lang="he"> Dotan Cohen http://lyricslist.com/lyrics/artist_albums/5/112.html http://what-is-what.com/what_is/website.html -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
RE: [PHP] Latin letter problem!
How are you setting the charset of the web page? Are you using header() or using html head section to set it? Best regards, Peter Lauri www.dwsasia.com - company web site www.lauri.se - personal web site www.carbonfree.org.uk - become Carbon Free -Original Message- From: Delta Storm [mailto:[EMAIL PROTECTED] Sent: Tuesday, February 20, 2007 6:04 PM To: php-general@lists.php.net Subject: [PHP] Latin letter problem! Hi, I'm building an simple CMS system. I have built almost everything but one thing buggs me... I have a MySQL database built for publishing news (Id,title,newsContent,timestamp). And I have a php web page that displays that content. The problem is with the charset, in the database the settings are following: character set latin2 collation latin2_croatian_ci; and in the tables character set utf8; I display the data in the php page using utf8 I see all the non-PHP content pure HTML content capable of seeing croatian letter čćžšđ, but in the news section I only see čćđ. But they are on the same page! I tried putting other HTML charsets like iso-8859-1,iso-8859-2 etc... But in all the scenarios I get the HTMl part working but PHP not working vice-versa... Please help me it is a very important web page if you need any other information just ask! Thank you very much in advance! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
Re: [PHP] Latin letter problem!
On 20/02/07, Delta Storm <[EMAIL PROTECTED]> wrote: Hi, I'm building an simple CMS system. I have built almost everything but one thing buggs me... I have a MySQL database built for publishing news (Id,title,newsContent,timestamp). And I have a php web page that displays that content. The problem is with the charset, in the database the settings are following: character set latin2 collation latin2_croatian_ci; and in the tables character set utf8; I display the data in the php page using utf8 I see all the non-PHP content pure HTML content capable of seeing croatian letter čćžšđ, but in the news section I only see čćđ. But they are on the same page! I tried putting other HTML charsets like iso-8859-1,iso-8859-2 etc... But in all the scenarios I get the HTMl part working but PHP not working vice-versa... Please help me it is a very important web page if you need any other information just ask! Thank you very much in advance! Change it all to utf-8, and watch your problems disappear! I've lots of experience with that in Hebrew website design. Note that you will need the server to specify the utf-8 encoding in the header. The metatag is not enough. Dotan Cohen http://what-is-what.com/what_is/buffer_overflow.html http://lyricslist.com/lyrics/lyrics/47/402/pink_floyd/the_division_bell.html
[PHP] Latin letter problem!
Hi, I'm building an simple CMS system. I have built almost everything but one thing buggs me... I have a MySQL database built for publishing news (Id,title,newsContent,timestamp). And I have a php web page that displays that content. The problem is with the charset, in the database the settings are following: character set latin2 collation latin2_croatian_ci; and in the tables character set utf8; I display the data in the php page using utf8 I see all the non-PHP content pure HTML content capable of seeing croatian letter čćžšđ, but in the news section I only see čćđ. But they are on the same page! I tried putting other HTML charsets like iso-8859-1,iso-8859-2 etc... But in all the scenarios I get the HTMl part working but PHP not working vice-versa... Please help me it is a very important web page if you need any other information just ask! Thank you very much in advance! -- PHP General Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php