<?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: Eye of the Beholder</title>
	<atom:link href="http://www.jeremyprivett.com/blog/archives/eye-of-the-beholder/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.jeremyprivett.com/blog/archives/eye-of-the-beholder/</link>
	<description>Programming and Life</description>
	<lastBuildDate>Tue, 29 Sep 2009 22:01:20 -0400</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Karl</title>
		<link>http://www.jeremyprivett.com/blog/archives/eye-of-the-beholder/comment-page-1/#comment-106143</link>
		<dc:creator>Karl</dc:creator>
		<pubDate>Fri, 23 May 2008 02:23:40 +0000</pubDate>
		<guid isPermaLink="false">http://www.jeremyprivett.com/blog/?p=248#comment-106143</guid>
		<description>Jeremy: I wrote my article when PHP5 was mature. The point isn&#039;t that PHP doesn&#039;t support them, it&#039;s that those features aren&#039;t used. Oh, I&#039;m sure there are plenty of good examples where they are...but I&#039;m equally sure that there are far, far, far more where they aren&#039;t. 

Specifically, and honestly the point I haven&#039;t really seen well defended, is that PHP itself (not as a language, but as a framework and a library) doesn&#039;t make use of these features. Take for example the documentation for mysqli - the improved OO library for dealing with mysql:

$mysqli = new mysqli(&quot;localhost&quot;, &quot;my_user&quot;, &quot;my_password&quot;, &quot;world&quot;);

/* check connection */
if (mysqli_connect_errno()) {
    printf(&quot;Connect failed: %s\n&quot;, mysqli_connect_error());
    exit();
}

why doesn&#039;t mysqli throw an exception if a connetion fails? Why aren&#039;t errno and error instance members?

For backwards compatibility? Fair enough, but does that mean it doesn&#039;t suck? I don&#039;t think so.

If the library you build your application on isn&#039;t solid, can you truly build a maintainable app? Absolutely - but you really are starting at a disadvantage.</description>
		<content:encoded><![CDATA[<p>Jeremy: I wrote my article when PHP5 was mature. The point isn&#8217;t that PHP doesn&#8217;t support them, it&#8217;s that those features aren&#8217;t used. Oh, I&#8217;m sure there are plenty of good examples where they are&#8230;but I&#8217;m equally sure that there are far, far, far more where they aren&#8217;t. </p>
<p>Specifically, and honestly the point I haven&#8217;t really seen well defended, is that PHP itself (not as a language, but as a framework and a library) doesn&#8217;t make use of these features. Take for example the documentation for mysqli &#8211; the improved OO library for dealing with mysql:</p>
<p>$mysqli = new mysqli(&#8221;localhost&#8221;, &#8220;my_user&#8221;, &#8220;my_password&#8221;, &#8220;world&#8221;);</p>
<p>/* check connection */<br />
if (mysqli_connect_errno()) {<br />
    printf(&#8221;Connect failed: %s\n&#8221;, mysqli_connect_error());<br />
    exit();<br />
}</p>
<p>why doesn&#8217;t mysqli throw an exception if a connetion fails? Why aren&#8217;t errno and error instance members?</p>
<p>For backwards compatibility? Fair enough, but does that mean it doesn&#8217;t suck? I don&#8217;t think so.</p>
<p>If the library you build your application on isn&#8217;t solid, can you truly build a maintainable app? Absolutely &#8211; but you really are starting at a disadvantage.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

