<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>work in progress ... &#187; single-quotes</title>
	<atom:link href="http://blog.tobias-olry.de/tag/single-quotes/feed" rel="self" type="application/rss+xml" />
	<link>http://blog.tobias-olry.de</link>
	<description>... Stillstand gibt's nicht! (von Tobias Olry)</description>
	<lastBuildDate>Thu, 24 Sep 2009 06:44:42 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>php escaping in single-quotes</title>
		<link>http://blog.tobias-olry.de/php-escaping-in-single-quotes</link>
		<comments>http://blog.tobias-olry.de/php-escaping-in-single-quotes#comments</comments>
		<pubDate>Sun, 02 Aug 2009 19:02:47 +0000</pubDate>
		<dc:creator>Tobias</dc:creator>
				<category><![CDATA[all]]></category>
		<category><![CDATA[backslash]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[single-quotes]]></category>

		<guid isPermaLink="false">http://blog.tobias-olry.de/?p=69</guid>
		<description><![CDATA[<p>just discovered this strange behaviour in php, quite irritating actually:</p>

echo '\\.'.&#34;\n&#34;;
echo '\.'.&#34;\n&#34;;

<p>output:</p>
\.
\.
<p>to get two backslashes while using single-quotes, you need to do the following</p>

echo '\\\.'.&#34;\n&#34;;

]]></description>
			<content:encoded><![CDATA[<p>just discovered this strange behaviour in php, quite irritating actually:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'\\.'</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span>
<span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'\.'</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span></pre></div></div>

<p>output:</p>
<pre>\.
\.</pre>
<p>to get two backslashes while using single-quotes, you need to do the following</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #b1b100;">echo</span> <span style="color: #0000ff;">'\\\.'</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;<span style="color: #000099; font-weight: bold;">\n</span>&quot;</span><span style="color: #339933;">;</span></pre></div></div>

]]></content:encoded>
			<wfw:commentRss>http://blog.tobias-olry.de/php-escaping-in-single-quotes/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

