<?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>Code in my Bug!!! &#187; programming</title>
	<atom:link href="http://projectbee.org/blog/archive/category/programming/feed/" rel="self" type="application/rss+xml" />
	<link>http://projectbee.org/blog</link>
	<description>Bipin on Technology, Programming, Security, Hacking, &#38; Life.</description>
	<lastBuildDate>Mon, 23 Mar 2009 05:44:26 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
		<item>
		<title>Proposal for a new Array Syntax in PHP</title>
		<link>http://projectbee.org/blog/archive/proposal-for-a-new-array-syntax-in-php/</link>
		<comments>http://projectbee.org/blog/archive/proposal-for-a-new-array-syntax-in-php/#comments</comments>
		<pubDate>Sun, 13 Jan 2008 15:04:24 +0000</pubDate>
		<dc:creator>Bipin 3 Upadhyay</dc:creator>
				<category><![CDATA[news]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[programming]]></category>
		<category><![CDATA[code]]></category>
		<category><![CDATA[education]]></category>
		<category><![CDATA[rasmus]]></category>

		<guid isPermaLink="false">http://codeinmybug.wordpress.com/2008/01/13/proposal-for-a-new-array-syntax-in-php/</guid>
		<description><![CDATA[A new array syntax has been proposed (for quite some time) for defining arrays in PHP. Currently, we use array() construct to create an array. Some examples could be: $myArray = array(1, 2, 3, 4, 5); $yourArray = array(1 =&#62; &#8220;one&#8221;, 2 =&#62; &#8220;two&#8221;, &#8220;three&#8221;); $herArray = array(1, 2, 3, array(4 =&#62; &#8220;four&#8221;, &#8220;five&#8221;)); The [...]]]></description>
			<content:encoded><![CDATA[<p><img class="alignright" style="float: right;" src="http://projectbee.org/blog/wp-content/uploads/2008/01/php.gif" alt="PHP Logo" width="129" height="72" align="right" />A new array syntax has been proposed (for quite some time) for defining arrays in PHP. Currently, we use <a href="http://in2.php.net/manual/en/function.array.php">array()</a> construct to create an array. Some examples could be:</p>
<blockquote><p><em>$myArray = array(1, 2, 3, 4, 5);<br />
$yourArray = array(1 =&gt; &#8220;one&#8221;, 2 =&gt; &#8220;two&#8221;, &#8220;three&#8221;);<br />
$herArray = array(1, 2, 3, array(4 =&gt; &#8220;four&#8221;, &#8220;five&#8221;));</em></p></blockquote>
<p>The proposal is to use square brackets ( <strong>[ ] </strong>) to define an array. If passed, we would be able rewrite the above examples as:</p>
<blockquote><p><em><br />
$myArray = [1, 2, 3, 4, 5];<br />
$yourArray = [1 =&gt; "one", 2 =&gt; "two", "three");<br />
$herArray = [1, 2, 3, [4 =&gt; "four", "five"]];</em></p></blockquote>
<p>There&#8217;s a good deal of discussion going on in the internal mailing list with almost equal number of people voting &#8220;for&#8221; and &#8220;against&#8221; it. <a href="http://aspn.activestate.com/ASPN/Mail/Message/php-Dev/3598121" class="broken_link">Rasmus, isn&#8217;t not very supportive, yet has voted for the new proposal</a>.</p>
<p>To be pretty honest, I am still not very sure if it&#8217;s going to be worth the trade-offs.<br />
Anyhoo! Let&#8217;s wait and watch. <img src='http://projectbee.org/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
Similar Posts:<ul><li><a href="http://projectbee.org/blog/archive/reviving-owasp-bangalore-chapter/" rel="bookmark" title="June 29, 2008">Reviving OWASP Bangalore Chapter</a></li>

<li><a href="http://projectbee.org/blog/archive/how-to-implementing-shindig/" rel="bookmark" title="September 30, 2008">[How To] Implementing Shindig.</a></li>

<li><a href="http://projectbee.org/blog/archive/what-a-new-year-gift/" rel="bookmark" title="January 5, 2008">What a new year Gift! :)</a></li>

<li><a href="http://projectbee.org/blog/archive/no-more-lectures-now/" rel="bookmark" title="July 26, 2008">No more lectures now&#8230;</a></li>

<li><a href="http://projectbee.org/blog/archive/owasp-appsec-conf-delhi-day-2-and-more/" rel="bookmark" title="September 4, 2008">OWASP AppSec Conf Delhi &#8211; Day 2; and more</a></li>
</ul><!-- Similar Posts took 8.000 ms -->]]></content:encoded>
			<wfw:commentRss>http://projectbee.org/blog/archive/proposal-for-a-new-array-syntax-in-php/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
<!-- WP Super Cache is installed but broken. The path to wp-cache-phase1.php in wp-content/advanced-cache.php must be fixed! -->