<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Fri, 09 Jan 2009 22:55:33 -0600</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[David Otton's Blog: Stupid PHP Tricks: Illegal Variable Names]]></title>
      <guid>http://www.phpdeveloper.org/news/10885</guid>
      <link>http://www.phpdeveloper.org/news/10885</link>
      <description><![CDATA[<p>
<i>David Otton</i> has shared another of his "stupid PHP tricks" on his blog today. <A href="http://www.otton.org/2008/08/21/stupid-php-tricks-illegal-variable-names/">This one</a> looks at illegal variable names that don't match the "can't start with a number" rule the manual points out.
</p>
<blockquote>
A valid variable name starts with a letter or underscore, followed by any number of letters, numbers, or underscores. As a regular expression, it would be expressed thus: '[a-zA-Z_x7f-xff][a-zA-Z0-9_x7f-xff]*'
</blockquote>
<p>
Technically, you can get around this in two different ways - variable varaibles and the more complex notation with curly braces. He points to the <a href="http://www.php.net/compact">compact</a> function for proof that they're set.
</p>]]></description>
      <pubDate>Fri, 22 Aug 2008 13:47:52 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[PHP-Coding-Practices.com: Try-Catch Syntax Weirdness]]></title>
      <guid>http://www.phpdeveloper.org/news/8108</guid>
      <link>http://www.phpdeveloper.org/news/8108</link>
      <description><![CDATA[<p>
In working with his code recently, <i>Tim Koschuetzki</i> <a href="http://php-coding-practices.com/language-specific/try-catch-syntax-weirdness/">noticed something odd</a> with a block of try/catch code:
</p>
<blockquote>
I just noticed today, that PHP's try catch blocks require curly braces. Anybody has an idea why it is like that? I have used curly braces by default up until now, so I just stumbled upon this weirdness today.
</blockquote>
<p>
He includes two examples, one with a curly brace after the catch clause and the other without. This is different than several other control structures (like ifs) that don't require the curly brace when there's only the one line following it.
</p>]]></description>
      <pubDate>Fri, 22 Jun 2007 13:28:00 -0500</pubDate>
    </item>
  </channel>
</rss>
