<?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: Fixing Curly Quotes and Em Dashes in PHP</title>
	<atom:link href="http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/</link>
	<description>Bitterness never tasted so sweet</description>
	<lastBuildDate>Tue, 24 Jan 2012 02:52:00 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Aslasfweutt</title>
		<link>http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/comment-page-1/#comment-10745</link>
		<dc:creator>Aslasfweutt</dc:creator>
		<pubDate>Thu, 12 Jan 2012 13:33:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.snipe.net/?p=476#comment-10745</guid>
		<description>I&#039;ve copied the codes that worked for me: https://pzt.me/9l95 </description>
		<content:encoded><![CDATA[<p>I&#8217;ve copied the codes that worked for me: <a href="https://pzt.me/9l95" rel="nofollow">https://pzt.me/9l95</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Falyuteis</title>
		<link>http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/comment-page-1/#comment-10454</link>
		<dc:creator>Falyuteis</dc:creator>
		<pubDate>Mon, 06 Jun 2011 14:51:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.snipe.net/?p=476#comment-10454</guid>
		<description>They do this also in client side with JavaScript in http://www.kevinkorb.com/post/37

The problem is that in many blogs and other websites they do the opposite: you enter data with the keyboard default quotes (vertical) and when you submit they convert them to curly ones ( they can do for example with http://pastebin.com/CEK0NN43 ). If the submited data is a computer code you have normally to put the quotes as straight again so the code works.

In client side they do the opposite like shown in http://stackoverflow.com/questions/2202811/converting-straight-quotes-to-curly-quotes </description>
		<content:encoded><![CDATA[<p>They do this also in client side with JavaScript in <a href="http://www.kevinkorb.com/post/37" rel="nofollow">http://www.kevinkorb.com/post/37</a></p>
<p>The problem is that in many blogs and other websites they do the opposite: you enter data with the keyboard default quotes (vertical) and when you submit they convert them to curly ones ( they can do for example with <a href="http://pastebin.com/CEK0NN43" rel="nofollow">http://pastebin.com/CEK0NN43</a> ). If the submited data is a computer code you have normally to put the quotes as straight again so the code works.</p>
<p>In client side they do the opposite like shown in <a href="http://stackoverflow.com/questions/2202811/converting-straight-quotes-to-curly-quotes" rel="nofollow">http://stackoverflow.com/questions/2202811/converting-straight-quotes-to-curly-quotes</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Justwrittennow</title>
		<link>http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/comment-page-1/#comment-10451</link>
		<dc:creator>Justwrittennow</dc:creator>
		<pubDate>Fri, 03 Jun 2011 20:24:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.snipe.net/?p=476#comment-10451</guid>
		<description>This simpler version also does it: http://notepub.com/#note=197532</description>
		<content:encoded><![CDATA[<p>This simpler version also does it: <a href="http://notepub.com/#note=197532" rel="nofollow">http://notepub.com/#note=197532</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: snipe</title>
		<link>http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/comment-page-1/#comment-10450</link>
		<dc:creator>snipe</dc:creator>
		<pubDate>Fri, 03 Jun 2011 20:19:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.snipe.net/?p=476#comment-10450</guid>
		<description>Just so you know, using a fake email address means I can&#039;t whitelist you so your comments can&#039;t be automatically approved. I don&#039;t much care one way or another, but I thought you should know.</description>
		<content:encoded><![CDATA[<p>Just so you know, using a fake email address means I can&#8217;t whitelist you so your comments can&#8217;t be automatically approved. I don&#8217;t much care one way or another, but I thought you should know.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Justwrote</title>
		<link>http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/comment-page-1/#comment-10449</link>
		<dc:creator>Justwrote</dc:creator>
		<pubDate>Fri, 03 Jun 2011 20:16:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.snipe.net/?p=476#comment-10449</guid>
		<description>If the code doesn&#039;t appear well you can copy it from: http://notepub.com/#note=197525

Just remove the blank space after the first character (less-than, similar to bracket. </description>
		<content:encoded><![CDATA[<p>If the code doesn&#8217;t appear well you can copy it from: <a href="http://notepub.com/#note=197525" rel="nofollow">http://notepub.com/#note=197525</a></p>
<p>Just remove the blank space after the first character (less-than, similar to bracket.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Iuaspel</title>
		<link>http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/comment-page-1/#comment-10448</link>
		<dc:creator>Iuaspel</dc:creator>
		<pubDate>Fri, 03 Jun 2011 20:04:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.snipe.net/?p=476#comment-10448</guid>
		<description>Thanks. But for me it doesn&#039;t work.

I get â€œ before “ or &#8220; (left double quotation mark) and â€ after ” or &#8221; (right double quotation mark).

For me works well this function:



Adapted from http://www.toao.net/48-replacing-smart-quotes-and-em-dashes-in-mysql</description>
		<content:encoded><![CDATA[<p>Thanks. But for me it doesn&#8217;t work.</p>
<p>I get â€œ before “ or &ldquo; (left double quotation mark) and â€ after ” or &rdquo; (right double quotation mark).</p>
<p>For me works well this function:</p>
<p>Adapted from <a href="http://www.toao.net/48-replacing-smart-quotes-and-em-dashes-in-mysql" rel="nofollow">http://www.toao.net/48-replacing-smart-quotes-and-em-dashes-in-mysql</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Scott</title>
		<link>http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/comment-page-1/#comment-8086</link>
		<dc:creator>Scott</dc:creator>
		<pubDate>Thu, 11 Feb 2010 21:35:35 +0000</pubDate>
		<guid isPermaLink="false">http://www.snipe.net/?p=476#comment-8086</guid>
		<description>There&#039;s no reason to stop with just smart quotes.  You can fix all manner of illegal characters with the following:&lt;br&gt;&lt;br&gt;$allEntities        = get_html_translation_table(HTML_ENTITIES, ENT_NOQUOTES);&lt;br&gt;$specialEntities    = get_html_translation_table(HTML_SPECIALCHARS, ENT_NOQUOTES);&lt;br&gt;$noTags             = array_diff($allEntities, $specialEntities);&lt;br&gt;&lt;br&gt;And, that will leave tags alone, assuming that&#039;s what you want.&lt;br&gt;$valid = strtr($invalid, $noTags);</description>
		<content:encoded><![CDATA[<p>There&#39;s no reason to stop with just smart quotes.  You can fix all manner of illegal characters with the following:</p>
<p>$allEntities        = get_html_translation_table(HTML_ENTITIES, ENT_NOQUOTES);<br />$specialEntities    = get_html_translation_table(HTML_SPECIALCHARS, ENT_NOQUOTES);<br />$noTags             = array_diff($allEntities, $specialEntities);</p>
<p>And, that will leave tags alone, assuming that&#39;s what you want.<br />$valid = strtr($invalid, $noTags);</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: snipe</title>
		<link>http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/comment-page-1/#comment-7199</link>
		<dc:creator>snipe</dc:creator>
		<pubDate>Thu, 17 Sep 2009 15:44:37 +0000</pubDate>
		<guid isPermaLink="false">http://www.snipe.net/?p=476#comment-7199</guid>
		<description>@Don - you could either include the function on the same page as the script where your text would be displayed, or within a functions file that you include in that file. Check out this tutorial on using functions in PHP for more info: http://www.php-mysql-tutorial.com/wikis/php-tutorial/php-functions.aspx</description>
		<content:encoded><![CDATA[<p>@Don &#8211; you could either include the function on the same page as the script where your text would be displayed, or within a functions file that you include in that file. Check out this tutorial on using functions in PHP for more info: <a href="http://www.php-mysql-tutorial.com/wikis/php-tutorial/php-functions.aspx" rel="nofollow">http://www.php-mysql-tutorial.com/wikis/php-tutorial/php-functions.aspx</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: snipe</title>
		<link>http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/comment-page-1/#comment-9250</link>
		<dc:creator>snipe</dc:creator>
		<pubDate>Thu, 17 Sep 2009 15:44:00 +0000</pubDate>
		<guid isPermaLink="false">http://www.snipe.net/?p=476#comment-9250</guid>
		<description>@Don - you could either include the function on the same page as the script where your text would be displayed, or within a functions file that you include in that file. Check out this tutorial on using functions in PHP for more info: http://www.php-mysql-tutorial.com/wikis/php-tutorial/php-functions.aspx</description>
		<content:encoded><![CDATA[<p>@Don &#8211; you could either include the function on the same page as the script where your text would be displayed, or within a functions file that you include in that file. Check out this tutorial on using functions in PHP for more info: <a href="http://www.php-mysql-tutorial.com/wikis/php-tutorial/php-functions.aspx" rel="nofollow">http://www.php-mysql-tutorial.com/wikis/php-tutorial/php-functions.aspx</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Don De.</title>
		<link>http://www.snipe.net/2008/12/fixing-curly-quotes-and-em-dashes-in-php/comment-page-1/#comment-7198</link>
		<dc:creator>Don De.</dc:creator>
		<pubDate>Thu, 17 Sep 2009 15:39:21 +0000</pubDate>
		<guid isPermaLink="false">http://www.snipe.net/?p=476#comment-7198</guid>
		<description>I don&#039;t get it. How do I use this function? Do I use it on the page where the text is? Do I say &quot;&quot; etc. Sorry I&#039;m so stupid.

Don</description>
		<content:encoded><![CDATA[<p>I don&#8217;t get it. How do I use this function? Do I use it on the page where the text is? Do I say &#8220;&#8221; etc. Sorry I&#8217;m so stupid.</p>
<p>Don</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Dynamic page generated in 0.559 seconds. -->
<!-- Cached page generated by WP-Super-Cache on 2012-01-25 15:11:57 -->

