<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: UTF8 in PHP and MySQL</title>
	<atom:link href="http://www.charles-reace.com/blog/2008/10/03/utf8-in-php-and-mysql/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.charles-reace.com/blog/2008/10/03/utf8-in-php-and-mysql/</link>
	<description>Random thoughts about PHP, MySQL, and life in general</description>
	<lastBuildDate>Sat, 10 Jul 2010 21:22:46 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Felix</title>
		<link>http://www.charles-reace.com/blog/2008/10/03/utf8-in-php-and-mysql/comment-page-1/#comment-1744</link>
		<dc:creator>Felix</dc:creator>
		<pubDate>Tue, 31 Mar 2009 09:26:20 +0000</pubDate>
		<guid isPermaLink="false">http://www.charles-reace.com/blog/?p=103#comment-1744</guid>
		<description>Regarding the 2008/10/04 addition: I think using htmlentities($string, ENT_COMPAT, &quot;UTF-8&quot;); should work fine and it would even be safer than htmlspecialchars() because it will convert more characters. :-)</description>
		<content:encoded><![CDATA[<p>Regarding the 2008/10/04 addition: I think using htmlentities($string, ENT_COMPAT, &#8220;UTF-8&#8243;); should work fine and it would even be safer than htmlspecialchars() because it will convert more characters. :-)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Felix</title>
		<link>http://www.charles-reace.com/blog/2008/10/03/utf8-in-php-and-mysql/comment-page-1/#comment-1728</link>
		<dc:creator>Felix</dc:creator>
		<pubDate>Mon, 06 Oct 2008 18:24:01 +0000</pubDate>
		<guid isPermaLink="false">http://www.charles-reace.com/blog/?p=103#comment-1728</guid>
		<description>&lt;a href=&quot;http://znupi.ath.cx/files/Screenshot-1.png&quot; rel=&quot;nofollow&quot;&gt;Here&#039;s how&lt;/a&gt; :)
Mozilla Firefox 3.0.3 / Ubuntu 8.04
As you can see, the textbox can easily be widened :)</description>
		<content:encoded><![CDATA[<p><a href="http://znupi.ath.cx/files/Screenshot-1.png" rel="nofollow">Here&#8217;s how</a> :)<br />
Mozilla Firefox 3.0.3 / Ubuntu 8.04<br />
As you can see, the textbox can easily be widened :)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Charles</title>
		<link>http://www.charles-reace.com/blog/2008/10/03/utf8-in-php-and-mysql/comment-page-1/#comment-1727</link>
		<dc:creator>Charles</dc:creator>
		<pubDate>Mon, 06 Oct 2008 17:26:46 +0000</pubDate>
		<guid isPermaLink="false">http://www.charles-reace.com/blog/?p=103#comment-1727</guid>
		<description>&lt;blockquote cite=&quot;Felix&quot;&gt;Off topic: can you make this text box a bit wider? I’m getting a claustrophobic kind of feeling typing here&lt;/blockquote&gt;
How&#039;s this?</description>
		<content:encoded><![CDATA[<blockquote cite="Felix"><p>Off topic: can you make this text box a bit wider? I’m getting a claustrophobic kind of feeling typing here</p></blockquote>
<p>How&#8217;s this?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Felix</title>
		<link>http://www.charles-reace.com/blog/2008/10/03/utf8-in-php-and-mysql/comment-page-1/#comment-1726</link>
		<dc:creator>Felix</dc:creator>
		<pubDate>Mon, 06 Oct 2008 16:40:30 +0000</pubDate>
		<guid isPermaLink="false">http://www.charles-reace.com/blog/?p=103#comment-1726</guid>
		<description>Interesting :). Here&#039;s my experience with encodings and stuff like that (I&#039;m not an expert either):
I built this application which had a php script that ran in the command line and that was connecting to other servers and storing data in a database. This data would contain &quot;funny characters&quot;. The problem was not with inserting the data, which worked flawlessly (even though the tables and fields are set to the latin1_swedish_ci collation -- I think that&#039;s the default one phpmyadmin uses), but with reading the data. In phpmyadmin I would see the data just like it should appear, but in my own application it appeared incorrectly. I tried everything, utf8_decode(), iconv()m, etc. I was very frustrated and searched the web for hours, and came up with a simple solution:
mysql_query(&quot;SET NAMES &#039;utf8&#039;&quot;);
Pretty similar to yours, indeed :P. I should probably convert those tables to utf8_unicode_ci, shouldn&#039;t I?
Off topic: can you make this text box a bit wider? I&#039;m getting a claustrophobic kind of feeling typing here :P

Regards,
Felix.

PS: Yes! I&#039;m registered! :)</description>
		<content:encoded><![CDATA[<p>Interesting :). Here&#8217;s my experience with encodings and stuff like that (I&#8217;m not an expert either):<br />
I built this application which had a php script that ran in the command line and that was connecting to other servers and storing data in a database. This data would contain &#8220;funny characters&#8221;. The problem was not with inserting the data, which worked flawlessly (even though the tables and fields are set to the latin1_swedish_ci collation &#8212; I think that&#8217;s the default one phpmyadmin uses), but with reading the data. In phpmyadmin I would see the data just like it should appear, but in my own application it appeared incorrectly. I tried everything, utf8_decode(), iconv()m, etc. I was very frustrated and searched the web for hours, and came up with a simple solution:<br />
mysql_query(&#8220;SET NAMES &#8216;utf8&#8242;&#8221;);<br />
Pretty similar to yours, indeed :P. I should probably convert those tables to utf8_unicode_ci, shouldn&#8217;t I?<br />
Off topic: can you make this text box a bit wider? I&#8217;m getting a claustrophobic kind of feeling typing here :P</p>
<p>Regards,<br />
Felix.</p>
<p>PS: Yes! I&#8217;m registered! :)</p>
]]></content:encoded>
	</item>
</channel>
</rss>
