<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>Made of Everything You're Not</title>
	
	<link>http://blog.ericlamb.net</link>
	<description>Thoughts on programming, people and life</description>
	<lastBuildDate>Wed, 11 Aug 2010 03:58:55 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
		<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/MadeOfEverythingYoureNot" /><feedburner:info uri="madeofeverythingyourenot" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><item>
		<title>Mailpress 5.0 Email Validation Bug</title>
		<link>http://feedproxy.google.com/~r/MadeOfEverythingYoureNot/~3/BpRB6WYoUCw/</link>
		<comments>http://blog.ericlamb.net/2010/08/mailpress-5-0-email-validation-bug/#comments</comments>
		<pubDate>Tue, 10 Aug 2010 07:00:20 +0000</pubDate>
		<dc:creator>Eric Lamb</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Rant]]></category>
		<category><![CDATA[JavaScript]]></category>
		<category><![CDATA[mailpress]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[wordpress plugin]]></category>

		<guid isPermaLink="false">http://blog.ericlamb.net/?p=3380</guid>
		<description><![CDATA[A couple weeks ago I received an email from a client of mine about a bug one of their clients was having using the Mailpress WordPress plugin and wanting to know if I could help. They&#8217;re an agency and I always want to make them happy so, even though I didn&#8217;t write Mailpress, I decided [...]]]></description>
			<content:encoded><![CDATA[<p>A couple weeks ago I received an email from a client of mine about a bug one of their clients was having using the <a title="Mailpress WordPress plugin" href="http://www.mailpress.org/wiki/index.php?title=Main_Page" onclick="return TrackClick('http%3A%2F%2Fwww.mailpress.org%2Fwiki%2Findex.php%3Ftitle%3DMain_Page','Mailpress+Wordpress+plugin')" target="_blank">Mailpress WordPress</a> plugin and wanting to know if I could help. They&#8217;re an agency and I always want to make them happy so, even though I didn&#8217;t write Mailpress, I decided to dive in a see what was up. Plus, it&#8217;s always fun to contribute to open source projects and to get <em>paid</em> to do it is always a win-win.</p>
<div id="attachment_3382" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/08/win-win.jpg" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F08%2Fwin-win.jpg','Mailpress+Email+Validation+Bug')"><img class="size-medium wp-image-3382" title="Mailpress Email Validation Bug" src="http://blog.ericlamb.net/wp-content/uploads/2010/08/win-win-300x225.jpg" alt="Mailpress Email Validation Bug" width="300" height="225" /></a><p class="wp-caption-text">Mailpress Email Validation Bug</p></div>
<p>Before getting into the bug I just want to say that I didn&#8217;t want to post it in this way; ideally there would be channels available to submit issues but Mailpress doesn&#8217;t exactly make that easy. Their site, while having links to the expected destinations like <a title="Mailpress Community" href="http://www.mailpress.org/wiki/index.php?title=MailPress:Community_Portal" onclick="return TrackClick('http%3A%2F%2Fwww.mailpress.org%2Fwiki%2Findex.php%3Ftitle%3DMailPress%3ACommunity_Portal','Mailpress+Community')" target="_blank">Community</a> and <a title="Mailpress Submitting a Patch" href="http://www.mailpress.org/wiki/index.php?title=Submitting_a_patch" onclick="return TrackClick('http%3A%2F%2Fwww.mailpress.org%2Fwiki%2Findex.php%3Ftitle%3DSubmitting_a_patch','Mailpress+Submitting+a+Patch')" target="_blank">Submitting a patch</a>, doesn&#8217;t appear to be finished and those sections are essentially empty at the moment.  The information to put this information out there very well might be in the site but, frankly, the thought of writing this post was less painful than digging through the site looking for info. Plus, this isn&#8217;t a security issue at all so there&#8217;s that. Ass == Covered.</p>
<p>The issue was that the email validation was returning false even when an email was valid, specifically if the email wasn&#8217;t entirely lowercase. The problem with that, in case it&#8217;s not clear, is that an email address doesn&#8217;t have to be lower case (at least in the name portion). For example the below two emails are valid and, in fact, different:</p>
<p>eric@example.com<br />
Eric@example.com</p>
<p>They look similar and it&#8217;s not really advisable to do email addresses in that format but people do it that way and, technically, it <em>is</em> allowed so not sure why Mailpress doesn&#8217;t. </p>
<p>Mailpress would throw an error on the second email which was pissing of my client&#8217;s client and my client (sigh&#8230;). The fix is pretty stratightford and easy; just replace the regular expression in Mailpress with the working one I cribbed from <a title="Validate email address using JavaScript regular expression" href="http://www.zparacha.com/validate-email-address-using-javascript-regular-expression/" onclick="return TrackClick('http%3A%2F%2Fwww.zparacha.com%2Fvalidate-email-address-using-javascript-regular-expression%2F','Validate+email+address+using+JavaScript+regular+expression')" target="_blank">Zaheer</a>.</p>
<p>File: &#8220;/wp-content/plugins/mailpress/mp-admin/js/write.js&#8221;</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>219
</pre></td><td class="code"><pre class="javascript" style="font-family:monospace;">is_email <span style="color: #339933;">:</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #000;">&#40;</span>m<span style="color: #000;">&#41;</span> <span style="color: #000;">&#123;</span> <span style="color: #003366; font-weight: bold;">var</span> pattern <span style="color: #339933;">=</span> <span style="color: #009966; font-style: italic;">/^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,4})$/</span><span style="color: #339933;">;</span> <span style="color: #22f;">return</span> pattern.<span style="color: #660066;">test</span><span style="color: #000;">&#40;</span>m<span style="color: #000;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000;">&#125;</span><span style="color: #339933;">,</span></pre></td></tr></table></div>

<p>With:</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>219
</pre></td><td class="code"><pre class="javascript" style="font-family:monospace;">is_email <span style="color: #339933;">:</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #000;">&#40;</span>m<span style="color: #000;">&#41;</span> <span style="color: #000;">&#123;</span> <span style="color: #003366; font-weight: bold;">var</span> pattern <span style="color: #339933;">=</span> <span style="color: #009966; font-style: italic;">/^[a-zA-Z0-9._-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,4}$/</span><span style="color: #339933;">;</span> <span style="color: #22f;">return</span> pattern.<span style="color: #660066;">test</span><span style="color: #000;">&#40;</span>m<span style="color: #000;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000;">&#125;</span><span style="color: #339933;">,</span></pre></td></tr></table></div>

<p>Hopefully, the issue doesn&#8217;t go deeper than the javascript validation but the above does allow for a working email validation script. Now we just need Mailpress to update their wonderful plugin with the fix&#8230;</p>
<img src="http://feeds.feedburner.com/~r/MadeOfEverythingYoureNot/~4/BpRB6WYoUCw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.ericlamb.net/2010/08/mailpress-5-0-email-validation-bug/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		<feedburner:origLink>http://blog.ericlamb.net/2010/08/mailpress-5-0-email-validation-bug/</feedburner:origLink></item>
		<item>
		<title>WP-Click-Track 0.7.2 Released</title>
		<link>http://feedproxy.google.com/~r/MadeOfEverythingYoureNot/~3/QJ3AJ-_cmM4/</link>
		<comments>http://blog.ericlamb.net/2010/08/wp-click-track-0-7-2-released/#comments</comments>
		<pubDate>Tue, 03 Aug 2010 21:07:03 +0000</pubDate>
		<dc:creator>Eric Lamb</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[wp-click-track]]></category>

		<guid isPermaLink="false">http://blog.ericlamb.net/?p=3371</guid>
		<description><![CDATA[Today I finally found the time to release an update to wp-click-track with a few bugs that some users have been encountering. This release is purely a bug fix release so there won&#8217;t be any new bells or whistles but if you run IIS 6 or want to clear out some links or reset your [...]]]></description>
			<content:encoded><![CDATA[<p>Today I finally found the time to release an update to wp-click-track with a few bugs that some users have been encountering. This release is purely a bug fix release so there won&#8217;t be any new bells or whistles but if you run IIS 6 or want to clear out some links or reset your system you&#8217;re in luck. The only &#8220;interesting&#8221; bug that was fixed was the IIS6 HTTPS issue.</p>
<div id="attachment_3374" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/08/microsoft-logo.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F08%2Fmicrosoft-logo.png','WP-Click-Track+0.7.2+Released')"><img src="http://blog.ericlamb.net/wp-content/uploads/2010/08/microsoft-logo-300x220.png" alt="WP-Click-Track 0.7.2 Released" title="WP-Click-Track 0.7.2 Released" width="300" height="220" class="size-medium wp-image-3374" /></a><p class="wp-caption-text">WP-Click-Track 0.7.2 Released</p></div>
<p>Because of how IIS6 and PHP populate the $_SERVER['HTTPS'] value some users were experiencing issues with their stats page. Turns out that <a href="http://php.net/manual/en/reserved.variables.server.php" onclick="return TrackClick('http%3A%2F%2Fphp.net%2Fmanual%2Fen%2Freserved.variables.server.php','IIS6+will+return+a+value+of+off')" title="IIS6 will return a value of off" target="_blank">IIS6 will return a value of &#8220;off&#8221;</a> if the request wasn&#8217;t made through HTTPS instead of the default behavior of returning a boolean. So, while the below code will work with Apache and newer versions of IIS, IIS6 creates a bit of a false positive:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #22f;">if</span><span style="color: #000;">&#40;</span><span style="color: #990000;">isset</span><span style="color: #000;">&#40;</span><span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTPS'</span><span style="color: #000;">&#93;</span><span style="color: #000;">&#41;</span><span style="color: #000;">&#41;</span>
<span style="color: #000;">&#123;</span>
     <span style="color: #666666; font-style: italic;">//server has HTTPS but IIS6 will always think it's on</span>
<span style="color: #000;">&#125;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>Instead, it&#8217;s better to check the value along with the existance check like:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #22f;">if</span><span style="color: #000;">&#40;</span><span style="color: #990000;">isset</span><span style="color: #000;">&#40;</span><span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTPS'</span><span style="color: #000;">&#93;</span><span style="color: #000;">&#41;</span> <span style="color: #339933;">&amp;&amp;</span> <span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTPS'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">!=</span> <span style="color: #0000ff;">'off'</span><span style="color: #000;">&#41;</span>
<span style="color: #000;">&#123;</span>
    <span style="color: #666666; font-style: italic;">//server has HTTPS and IIS6 is being account for</span>
<span style="color: #000;">&#125;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>Go Microsoft <img src='http://blog.ericlamb.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<img src="http://feeds.feedburner.com/~r/MadeOfEverythingYoureNot/~4/QJ3AJ-_cmM4" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.ericlamb.net/2010/08/wp-click-track-0-7-2-released/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		<feedburner:origLink>http://blog.ericlamb.net/2010/08/wp-click-track-0-7-2-released/</feedburner:origLink></item>
		<item>
		<title>ExpressionEngine White Screen Fix</title>
		<link>http://feedproxy.google.com/~r/MadeOfEverythingYoureNot/~3/roV2I0COVoc/</link>
		<comments>http://blog.ericlamb.net/2010/07/expressionengine-white-screen/#comments</comments>
		<pubDate>Thu, 29 Jul 2010 07:00:32 +0000</pubDate>
		<dc:creator>Eric Lamb</dc:creator>
				<category><![CDATA[Brain Dump]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[ExpressionEngine]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://blog.ericlamb.net/?p=3326</guid>
		<description><![CDATA[The more I work with ExpressionEngine the more I keep running into the same issues. ExpressionEngine hides most error messages, especially those related to configuration, probably for security, but this doesn&#8217;t make debugging any easier. To be fair, I don&#8217;t know if this is how ExpressionEngine works out of the box or if this is [...]]]></description>
			<content:encoded><![CDATA[<p>The more I work with <a href="http://expressionengine.com" onclick="return TrackClick('http%3A%2F%2Fexpressionengine.com','ExpressionEngine')" target="_blank" title="ExpressionEngine">ExpressionEngine</a> the more I keep running into the same issues. ExpressionEngine hides most error messages, especially those related to configuration, probably for security, but this doesn&#8217;t make debugging any easier. To be fair, I don&#8217;t know if this is how ExpressionEngine works out of the box or if this is a configuration setup done by the projects original developers but it does make fixing the issue that much harder.</p>
<div id="attachment_3333" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/07/whitescreen.jpg" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F07%2Fwhitescreen.jpg','Expression+Engine+White+Screen')"><img class="size-medium wp-image-3333" title="Expression Engine White Screen" src="http://blog.ericlamb.net/wp-content/uploads/2010/07/whitescreen-300x300.jpg" alt="ExpressionEngine White Screen" width="300" height="300" /></a><p class="wp-caption-text">ExpressionEngine White Screen</p></div>
<h3>Admin White Screen</h3>
<p>I&#8217;ve only come across the administration area throwing a white screen when using ExpressionEngine 1.67 on a PHP 5.3 server and only if extensions are enabled. I&#8217;m not sure if the newer versions of the 1.x branch have this fixed so this might not work for you.</p>
<p>The issue has to do with how the variables are being passed and called; PHP 5.3 changed how references were handled so the method ExpressionEngine 1.67 uses no longer works. To fix you have to modify &#8220;/system/core/core.extensions.php&#8221; with the below changes that are on the <a href="http://expressionengine.com/archived_forums/viewthread/121802/#603928" onclick="return TrackClick('http%3A%2F%2Fexpressionengine.com%2Farchived_forums%2Fviewthread%2F121802%2F%23603928','ExpressionEngine+forums')" target="_blank" title="ExpressionEngine forums">ExpressionEngine forums</a>:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #666666; font-style: italic;">//system/core/core.extensions.php around line 115 modify:</span>
<span style="color: #22f;">if</span> <span style="color: #000;">&#40;</span><span style="color: #990000;">sizeof</span><span style="color: #000;">&#40;</span><span style="color: #000088;">$args</span><span style="color: #000;">&#41;</span> <span style="color: #339933;">==</span> <span style="color: #cc66cc;">1</span><span style="color: #000;">&#41;</span>
<span style="color: #000;">&#123;</span>
    <span style="color: #000088;">$args</span> <span style="color: #339933;">=</span> <span style="color: #990000;">array</span><span style="color: #000;">&#40;</span><span style="color: #000088;">$which</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">''</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000;">&#125;</span>
&nbsp;
<span style="color: #22f;">if</span> <span style="color: #000;">&#40;</span><span style="color: #990000;">version_compare</span><span style="color: #000;">&#40;</span><span style="color: #009900; font-weight: bold;">PHP_VERSION</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'5.3'</span><span style="color: #000;">&#41;</span> <span style="color: #339933;">&gt;=</span> <span style="color: #cc66cc;">0</span><span style="color: #000;">&#41;</span>
<span style="color: #000;">&#123;</span>
    <span style="color: #22f;">foreach</span> <span style="color: #000;">&#40;</span><span style="color: #000088;">$args</span> <span style="color: #22f;">as</span> <span style="color: #000088;">$k</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$v</span><span style="color: #000;">&#41;</span>
    <span style="color: #000;">&#123;</span>
        <span style="color: #000088;">$args</span><span style="color: #000;">&#91;</span><span style="color: #000088;">$k</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=&amp;</span> <span style="color: #000088;">$args</span><span style="color: #000;">&#91;</span><span style="color: #000088;">$k</span><span style="color: #000;">&#93;</span><span style="color: #339933;">;</span>
    <span style="color: #000;">&#125;</span>            
<span style="color: #000;">&#125;</span>  
<span style="color: #000000; font-weight: bold;">?&gt;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #666666; font-style: italic;">//and likewise around line 174 modify:</span>
<span style="color: #000;">&#123;</span>
    <span style="color: #000088;">$php4_object</span> <span style="color: #339933;">=</span> <span style="color: #009900; font-weight: bold;">FALSE</span><span style="color: #339933;">;</span>
    <span style="color: #000088;">$args</span> <span style="color: #339933;">=</span> <span style="color: #990000;">array_slice</span><span style="color: #000;">&#40;</span><span style="color: #990000;">func_get_args</span><span style="color: #000;">&#40;</span><span style="color: #000;">&#41;</span><span style="color: #339933;">,</span> <span style="color: #cc66cc;">1</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000;">&#125;</span>
&nbsp;
<span style="color: #22f;">if</span> <span style="color: #000;">&#40;</span><span style="color: #990000;">version_compare</span><span style="color: #000;">&#40;</span><span style="color: #009900; font-weight: bold;">PHP_VERSION</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'5.3'</span><span style="color: #000;">&#41;</span> <span style="color: #339933;">&gt;=</span> <span style="color: #cc66cc;">0</span><span style="color: #000;">&#41;</span>
<span style="color: #000;">&#123;</span>
    <span style="color: #22f;">foreach</span> <span style="color: #000;">&#40;</span><span style="color: #000088;">$args</span> <span style="color: #22f;">as</span> <span style="color: #000088;">$k</span> <span style="color: #339933;">=&gt;</span> <span style="color: #000088;">$v</span><span style="color: #000;">&#41;</span>
    <span style="color: #000;">&#123;</span>
        <span style="color: #000088;">$args</span><span style="color: #000;">&#91;</span><span style="color: #000088;">$k</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=&amp;</span> <span style="color: #000088;">$args</span><span style="color: #000;">&#91;</span><span style="color: #000088;">$k</span><span style="color: #000;">&#93;</span><span style="color: #339933;">;</span>
    <span style="color: #000;">&#125;</span>            
<span style="color: #000;">&#125;</span>  
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<h3>Front End White Screen</h3>
<p>Then there&#8217;s the front end white screen; so far I&#8217;ve encountered this type of white screen in both the 1.6 and 2.0 branches of ExpressionEngine. Luckily, whenever I&#8217;ve ran into a white screen on the front site it&#8217;s always due to various path configurations which is easily fixed by over riding the configuration file. </p>
<p>Expression Engine is <a href="http://blog.ericlamb.net/2010/07/portability-is-a-good-thing/" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2F2010%2F07%2Fportability-is-a-good-thing%2F','Portability+Is+A+Good+Goal')" title="Portability Is A Good Goal">one of those programs</a> that stores as much as possible in the database including file and path directory paths. To get around this permanently I&#8217;ve gotten in the habit of using a default config.php file for all any Expression Engine site I work on; it&#8217;s the first thing I do before anything else.</p>
<p>This new configuration file uses the $_SERVER super global to dynamically determine the paths and makes allowances for development, staging and production environments.</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #22f;">if</span> <span style="color: #000;">&#40;</span> <span style="color: #339933;">!</span> <span style="color: #990000;">defined</span><span style="color: #000;">&#40;</span><span style="color: #0000ff;">'EXT'</span><span style="color: #000;">&#41;</span><span style="color: #000;">&#41;</span><span style="color: #000;">&#123;</span>
	<span style="color: #990000;">exit</span><span style="color: #000;">&#40;</span><span style="color: #0000ff;">'Invalid file request'</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000;">&#125;</span>
&nbsp;
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'app_version'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;167&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'license_number'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'debug'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;0&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'install_lock'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;1&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_hostname'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_username'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_password'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_name'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #22f;">if</span><span style="color: #000;">&#40;</span><span style="color: #0000ff;">'dev.site.com'</span> <span style="color: #339933;">==</span> <span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #000;">&#93;</span><span style="color: #000;">&#41;</span>
<span style="color: #000;">&#123;</span>
	<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_hostname'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_username'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_password'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_name'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000;">&#125;</span>
<span style="color: #22f;">elseif</span><span style="color: #000;">&#40;</span><span style="color: #0000ff;">'stage.site.com'</span> <span style="color: #339933;">==</span> <span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #000;">&#93;</span><span style="color: #000;">&#41;</span>
<span style="color: #000;">&#123;</span>
	<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_hostname'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_username'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_password'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_name'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>	
<span style="color: #000;">&#125;</span>
&nbsp;
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'avatar_url'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;http://&quot;</span><span style="color: #339933;">.</span><span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/images/avatars/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'avatar_path'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'DOCUMENT_ROOT'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/images/avatars/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'photo_url'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;http://&quot;</span><span style="color: #339933;">.</span><span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/images/member_photos/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'photo_path'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'DOCUMENT_ROOT'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/images/member_photos/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'sig_img_url'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;http://&quot;</span><span style="color: #339933;">.</span><span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/images/signature_attachments/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'sig_img_path'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'DOCUMENT_ROOT'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/images/signature_attachments/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'prv_msg_upload_path'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'DOCUMENT_ROOT'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/images/pm_attachments/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'theme_folder_url'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;http://&quot;</span><span style="color: #339933;">.</span><span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/themes/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'site_url'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;http://&quot;</span><span style="color: #339933;">.</span><span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'captcha_url'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;http://&quot;</span><span style="color: #339933;">.</span><span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/images/captchas/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'captcha_path'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'DOCUMENT_ROOT'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/images/captchas/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'emoticon_path'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;http://&quot;</span><span style="color: #339933;">.</span><span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/images/smileys/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'theme_folder_path'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'DOCUMENT_ROOT'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/themes/&quot;</span><span style="color: #339933;">;</span>	
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_type'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;mysql&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_prefix'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;exp&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'db_conntype'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;0&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'system_folder'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;system&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'cp_url'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;http://&quot;</span><span style="color: #339933;">.</span><span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/&quot;</span><span style="color: #339933;">.</span><span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'system_folder'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">.</span><span style="color: #0000ff;">&quot;/index.php&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'doc_url'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;http://expressionengine.com/docs/&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'cookie_prefix'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'is_system_on'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;y&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'allow_extensions'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;y&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$conf</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'multiple_sites_enabled'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">&quot;n&quot;</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>The above config is for the 1.x branch though most values should work for the 2.x branch with the addition of $config['tmpl_file_basepath'].</p>
<p>Hopefully, this should take care of those white screens.</p>
<img src="http://feeds.feedburner.com/~r/MadeOfEverythingYoureNot/~4/roV2I0COVoc" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.ericlamb.net/2010/07/expressionengine-white-screen/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.ericlamb.net/2010/07/expressionengine-white-screen/</feedburner:origLink></item>
		<item>
		<title>Portability Is A Good Goal</title>
		<link>http://feedproxy.google.com/~r/MadeOfEverythingYoureNot/~3/lv_j3GWTrlI/</link>
		<comments>http://blog.ericlamb.net/2010/07/portability-is-a-good-thing/#comments</comments>
		<pubDate>Tue, 27 Jul 2010 07:00:58 +0000</pubDate>
		<dc:creator>Eric Lamb</dc:creator>
				<category><![CDATA[Brain Dump]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[php]]></category>
		<category><![CDATA[program design]]></category>

		<guid isPermaLink="false">http://blog.ericlamb.net/?p=3115</guid>
		<description><![CDATA[For most web developers that I&#8217;ve met and worked with, at least, the concept of &#8220;hard coding&#8221; variable values, especially environment variables, is a definite &#8220;I will kill you and your first born if you do this&#8221; offense. Through a combination of painful moments, especially in the push to live phase, we all learned just [...]]]></description>
			<content:encoded><![CDATA[<p>For most web developers that I&#8217;ve met and worked with, at least, the concept of &#8220;hard coding&#8221; variable values, especially environment variables, is a definite &#8220;I will kill you and your first born if you do this&#8221; offense. Through a combination of painful moments, especially in the push to live phase, we all learned just how fucked up hard coding could make a day. </p>
<div id="attachment_3311" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/07/padlock.jpg" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F07%2Fpadlock.jpg','padlock')"><img class="size-medium wp-image-3311" title="padlock" src="http://blog.ericlamb.net/wp-content/uploads/2010/07/padlock-300x199.jpg" alt="padlock" width="300" height="199" /></a><p class="wp-caption-text">Portability Is A Good Goal</p></div>
<p>I&#8217;m telling you, it&#8217;s a special kind of pain when you&#8217;re frantically  trying to fix a site <em>you</em> broke through poor planning and  execution. </p>
<p>So, we do the most logical thing and abstract out all the system variables into a single point; either a config file or a database usually. For some reason we then go about our task feeling proud that we&#8217;ve stopped hard coding, oblivious to the fact that all we&#8217;ve done is just <em>minimized</em> the amount of hard coding. And that&#8217;s not enough.</p>
<p>According to WikiPedia <a href="http://en.wikipedia.org/wiki/Hard_coding" onclick="return TrackClick('http%3A%2F%2Fen.wikipedia.org%2Fwiki%2FHard_coding','hard+coding')" title="hard coding" target="_blank">hard coding</a></p>
<blockquote><p>&#8230;refers to the software development practice of embedding input or  configuration data directly into the <a title="Source code" href="http://en.wikipedia.org/wiki/Source_code" onclick="return TrackClick('http%3A%2F%2Fen.wikipedia.org%2Fwiki%2FSource_code','Source+code')">source  code</a> of a <a title="Computer program" href="http://en.wikipedia.org/wiki/Computer_program" onclick="return TrackClick('http%3A%2F%2Fen.wikipedia.org%2Fwiki%2FComputer_program','Computer+program')">program</a> or other executable object, or  fixed formatting of the data, instead of obtaining that data from  external sources or generating data or formatting in the program itself  with the given input.</p></blockquote>
<p>Now, while that explanation is appropriate for good old fashioned native development, to be sure, I don&#8217;t think it&#8217;s applicable to web development because for most sites the database is as much a part of the application as the code is (especially when doing maintenance work). By which I mean that, in my experience, storing environment values inside a database isn&#8217;t a good idea unless there&#8217;s no other way (sometimes a project requires the rules be broken).</p>
<p>Anywho, for most of us who don&#8217;t have the natural, innate, knowledge, learning <em>not</em> to hard code was <em> </em>a tough lesson because when we first started developing web sites it was natural to connect the idea of the web site with the code and server it was running on. Hell, I personally remember being shocked to find out it was actually <em>bad</em> to develop a site on the live/production server; just didn&#8217;t make sense at the time (stupid, I know). In hindsight it was an obviously silly and short sighted mindset to adopt but changing that was probably the most important choice I&#8217;ve made to improve the quality of my projects.</p>
<p>I was reminded of this with painful clarity when a whole slew of issues came up from a client I&#8217;m working with. During the course of transitioning dozens of their legacy sites to a new server, some of which hadn&#8217;t been updated since the projects were completed some years ago by coders long since forgotten, quite a few started having weird and, not a little insidious, bugs in the new environment. Looking deeper into the issues revealed a nasty amount of hard coding in not only the custom projects, which I would expect actually, but also from various third party commercial and open source projects that were used for the base of the sites. </p>
<p>Here&#8217;s an example of what I&#8217;m talking about in terms of your everyday configuration file hard coding along with an example of what I&#8217;ve learned to do:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #666666; font-style: italic;">//bad</span>
<span style="color: #000088;">$path</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'/var/www/mysite.com/html/'</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$url</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'http://www.mysite.com'</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$cache</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'/var/www/mysite.com/cache/'</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">//good</span>
<span style="color: #000088;">$path</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'DOCUMENT_ROOT'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$url</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'http://'</span><span style="color: #339933;">.</span><span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'HTTP_HOST'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$cache</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$url</span><span style="color: #339933;">.</span><span style="color: #0000ff;">'/../cache/'</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>All thanks to the $_SERVER variable, in PHP (though most languages have some way to get that info), you shouldn&#8217;t have to <em>ever</em> hard code the paths to pretty much anything within your site. Note though that when executing PHP through CLI scripts or using the exec() function all bets are off (though there are ways to get around that too like using variations on __FILE__ and dirname()). And, yes, there are circumstances that demand hard coding, I know, but those cases are few and far between and usually have people capable of making those changes. </p>
<p>It was the third party programs that really annoyed me though. I find it a little easier to accept an individual inexperienced coder&#8217;s exuberance in coming up with a base solution at zero hour. I&#8217;ve been there; an issue comes up and the quickest, and less painful, solution is to just throw the path in place with a perosnal promise to come back later and make it elegant. Then&#8230; well, life takes over and the promise is forgotten. Happens all the time. </p>
<p>On the other hand though, when dealing with third party projects, both open source and commercial, this type of hard coding, well, that just bugs the crap out of me. It seems like such an obvious design decision yet <a href="http://expressionengine.com/" onclick="return TrackClick('http%3A%2F%2Fexpressionengine.com%2F','Expression+Engine')" title="Expression Engine" target="_blank">Expression Engine</a>, <a href="http://www.zen-cart.com/" onclick="return TrackClick('http%3A%2F%2Fwww.zen-cart.com%2F','Zen+Cart')" title="Zen Cart" target="_blank">Zen Cart</a> and <a href="http://wordpress.com" onclick="return TrackClick('http%3A%2F%2Fwordpress.com','WordPress')" title="WordPress" target="_blank">WordPress</a> (for example) all hard code environment variables into the configuration files. </p>
<p>This is especially irritating to me because it&#8217;s been my experience that most websites move to a different server at one time or another, so it&#8217;s a given that configuration is going to be changed at some point. Keeping the pain of moving the site to a minimum rates a higher priority to me. And, unless I&#8217;m missing something, it seems that there&#8217;s very little difference between having your installation/configuration script write $_SERVER['DOCUMENT_ROOT'] versus &#8220;/var/www/html&#8221; to a configuration file. </p>
<p>Something like (as a base example with no sanitization):</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #22f;">if</span><span style="color: #000;">&#40;</span><span style="color: #000088;">$_POST</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'path'</span><span style="color: #000;">&#93;</span> <span style="color: #339933;">==</span> <span style="color: #000088;">$_SERVER</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'DOCUMENT_ROOT'</span><span style="color: #000;">&#93;</span><span style="color: #000;">&#41;</span>
<span style="color: #000;">&#123;</span>
    <span style="color: #000088;">$path</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'$_SERVER[\'DOCUMENT_ROOT\']'</span><span style="color: #339933;">;</span>
<span style="color: #000;">&#125;</span>
<span style="color: #22f;">else</span>
<span style="color: #000;">&#123;</span>
    <span style="color: #000088;">$path</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$_POST</span><span style="color: #000;">&#91;</span><span style="color: #0000ff;">'path'</span><span style="color: #000;">&#93;</span><span style="color: #339933;">;</span>
<span style="color: #000;">&#125;</span>
&nbsp;
<span style="color: #666666; font-style: italic;">//write it to the config file</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>As I mentioned above there are definitely times when $_SERVER['DOCUMENT_ROOT'] isn&#8217;t appropriate per the requirements or spec but for most projects that I&#8217;ve worked with replacing hard paths with the variable has been effective 99% of the time. </p>
<img src="http://feeds.feedburner.com/~r/MadeOfEverythingYoureNot/~4/lv_j3GWTrlI" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.ericlamb.net/2010/07/portability-is-a-good-thing/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<feedburner:origLink>http://blog.ericlamb.net/2010/07/portability-is-a-good-thing/</feedburner:origLink></item>
		<item>
		<title>Create Expression Engine Plugin</title>
		<link>http://feedproxy.google.com/~r/MadeOfEverythingYoureNot/~3/UasHKq8ns84/</link>
		<comments>http://blog.ericlamb.net/2010/06/create-expression-engine-plugin/#comments</comments>
		<pubDate>Tue, 08 Jun 2010 07:00:03 +0000</pubDate>
		<dc:creator>Eric Lamb</dc:creator>
				<category><![CDATA[Brain Dump]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[ExpressionEngine]]></category>
		<category><![CDATA[ExpressionEngine Plugin]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://blog.ericlamb.net/?p=3273</guid>
		<description><![CDATA[In Expression Engine Escaping Madness I laid out an issue I was experiencing with a client site. The issue was that there didn&#8217;t appear to be a method available to escape Expression Engine markup when it is mixed with php so there is a definite risk of parse errors using that technique (it&#8217;s not a [...]]]></description>
			<content:encoded><![CDATA[<p>In <a title="Expression Engine Escaping Madness" href="http://blog.ericlamb.net/2010/05/expression-engine-escaping-madness/" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2F2010%2F05%2Fexpression-engine-escaping-madness%2F','Expression+Engine+Escaping+Madness')" target="_self">Expression Engine Escaping Madness</a> I laid out an issue I was experiencing with a client site. The issue was that there didn&#8217;t appear to be a method available to escape Expression Engine markup when it is mixed with php so there is a definite risk of parse errors using that technique (it&#8217;s not a security issue or anything; I want to be clear on that). This made me nervous enough that I couldn&#8217;t let it go and kept thinking about how to get around the issue. The answer: write an Expression Engine plugin.Of course this meant I had to actually <em>learn</em> how to write an Expression Engine plugin first. Here are my notes <img src='http://blog.ericlamb.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<div id="attachment_3280" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/06/power_board.jpg" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F06%2Fpower_board.jpg','Create+Expression+Engine+Plugin')"><img class="size-medium wp-image-3280" title="Create Expression Engine Plugin" src="http://blog.ericlamb.net/wp-content/uploads/2010/06/power_board-300x225.jpg" alt="Create Expression Engine Plugin" width="300" height="225" /></a><p class="wp-caption-text">Create Expression Engine Plugin</p></div>
<p>First though credit where it&#8217;s due: for this example I used the <a title=" Number Format 1.1" href="http://expressionengine.com/downloads/details/number_format/" onclick="return TrackClick('http%3A%2F%2Fexpressionengine.com%2Fdownloads%2Fdetails%2Fnumber_format%2F','Number+Format+1.1')" target="_blank">number_format plugin</a> as a base so a lot of credit goes to Robert Wallis for the nicely written plugin I&#8217;m basically leaching from:)</p>
<p>An Expression Engine plugin is essentially a php class with at least one method that translates into an Expression Engine tag and used inside of Expression Engine templates (I don&#8217;t think they can be used inside of entries directly though I haven&#8217;t confirmed this). They are best left for small tasks though because they can&#8217;t have an administrative backend or integration with the Expression Engine l10n stuff or form processing or any manageable settings. No fun stuff for plugins&#8230;</p>
<p>Like most platforms there&#8217;s a few conventions that have to be followed but, also like most platforms, they aren&#8217;t too troublesome to work with. It should be noted that the syntax for the class uses the php4 syntax so dumb yourself down accordingly. </p>
<p>For example our plugin class will look like:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #000000; font-weight: bold;">class</span> Add_Slashes
<span style="color: #000;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">function</span> Add_Slashes<span style="color: #000;">&#40;</span><span style="color: #000;">&#41;</span>
	<span style="color: #000;">&#123;</span>
&nbsp;
        <span style="color: #000;">&#125;</span>
<span style="color: #000;">&#125;</span></pre></div></div>

<p>And the plugin will be executed with the below Expression Engine template tag:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000;">&#123;</span><span style="color: #990000;">exp</span><span style="color: #339933;">:</span>add_slashes<span style="color: #000;">&#125;</span>O<span style="color: #0000ff;">'Reilly{/exp:add_slashes}</span></pre></div></div>

<p>Now, it&#8217;s possible to create template tags that aren&#8217;t done in pairs but for this example I&#8217;m going to stick with pairs. In case it wasn&#8217;t obvious, if you wanted to have a plugin that has more than a single method you would call that method like:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000;">&#123;</span><span style="color: #990000;">exp</span><span style="color: #339933;">:</span>add_slashes<span style="color: #339933;">:</span>somethingelse<span style="color: #000;">&#125;</span>O<span style="color: #0000ff;">'Reilly{/exp:add_slashes:somethingelse}</span></pre></div></div>

<p>So that&#8217;s the basic syntax. The next thing that needs to be done is that a file has to be created inside the &#8220;/system/plugin/&#8221; folder. Note that I&#8217;m using the default name for that folder (system) so if you renamed it during the installation process use that instead. The file name must be lower case the same as the class name and it must have pi. as the prefix, and begin with the second segment of the tag. So, with our example plugin, the plugin name would be: pi.add_slashes.php. Simple enough. Once the file is saved to the location the plugin is installed. That&#8217;s how Expression Engine rolls.</p>
<p>Now we have a working plugin in theory but if you go into the plugin manager you&#8217;ll see an error about a missing variable as well as a distorted view of the page. We&#8217;re missing something; the $plugin_info array. </p>
<p>Every Expression Engine plugin should have a variable outside of the class called $plugin_info. For our example it should look like the below:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #000088;">$plugin_info</span> <span style="color: #339933;">=</span> <span style="color: #990000;">array</span><span style="color: #000;">&#40;</span>
	<span style="color: #0000ff;">'pi_name'</span>        <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'Add Slashes'</span><span style="color: #339933;">,</span>
	<span style="color: #0000ff;">'pi_version'</span>      <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'1.0'</span><span style="color: #339933;">,</span>
	<span style="color: #0000ff;">'pi_author'</span>       <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'Eric Lamb'</span><span style="color: #339933;">,</span>
	<span style="color: #0000ff;">'pi_author_url'</span>  <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'http://blog.ericlamb.net/'</span><span style="color: #339933;">,</span>
	<span style="color: #0000ff;">'pi_description'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'Exposes PHP\'s &lt;a href=&quot;http://php.net/manual/en/function.addslashes.php&quot;&gt;addslashes()&lt;/a&gt; function via EE tags.'</span><span style="color: #339933;">,</span>
	<span style="color: #0000ff;">'pi_usage'</span>        <span style="color: #339933;">=&gt;</span> Add_Slashes<span style="color: #339933;">::</span><span style="color: #004000;">usage</span><span style="color: #000;">&#40;</span><span style="color: #000;">&#41;</span>
<span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>Obviously, the above lists all the details about the plugin for display in the plugin administration module:<br />
<div id="attachment_3293" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/06/ee-pm.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F06%2Fee-pm.png','Expression+Engine+Plugin+Manager')"><img src="http://blog.ericlamb.net/wp-content/uploads/2010/06/ee-pm-300x168.png" alt="Expression Engine Plugin Manager" title="Expression Engine Plugin Manager" width="300" height="168" class="size-medium wp-image-3293" /></a><p class="wp-caption-text">Expression Engine Plugin Manager</p></div></p>
<p>You may have noticed the pi_usage key in the array; this method is recommended by the <a title="Expression Engine Developer Center" href="http://expressionengine.com/developers/" onclick="return TrackClick('http%3A%2F%2Fexpressionengine.com%2Fdevelopers%2F','Expression+Engine+Developer+Center')" target="_blank">Expression Engine Developer Center</a> for describing the usage of a plugin. Inside the plugin create a method called usage() and just return the instructions. Those instructions will be used on the plugin description page:</p>
<div id="attachment_3295" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/06/ee-pi.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F06%2Fee-pi.png','Expression+Engine+Plugin+Information')"><img src="http://blog.ericlamb.net/wp-content/uploads/2010/06/ee-pi-300x168.png" alt="Expression Engine Plugin Information" title="Expression Engine Plugin Information" width="300" height="168" class="size-medium wp-image-3295" /></a><p class="wp-caption-text">Expression Engine Plugin Information</p></div>
<p>Using all of the above the completed plugin is below:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #000088;">$plugin_info</span> <span style="color: #339933;">=</span> <span style="color: #990000;">array</span><span style="color: #000;">&#40;</span>
	<span style="color: #0000ff;">'pi_name'</span>        <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'Add Slashes'</span><span style="color: #339933;">,</span>
	<span style="color: #0000ff;">'pi_version'</span>      <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'1.0'</span><span style="color: #339933;">,</span>
	<span style="color: #0000ff;">'pi_author'</span>       <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'Eric Lamb'</span><span style="color: #339933;">,</span>
	<span style="color: #0000ff;">'pi_author_url'</span>  <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'http://blog.ericlamb.net/'</span><span style="color: #339933;">,</span>
	<span style="color: #0000ff;">'pi_description'</span> <span style="color: #339933;">=&gt;</span> <span style="color: #0000ff;">'Exposes PHP\'s &lt;a href=&quot;http://php.net/manual/en/function.addslashes.php&quot;&gt;addslashes()&lt;/a&gt; function via EE tags.'</span><span style="color: #339933;">,</span>
	<span style="color: #0000ff;">'pi_usage'</span>        <span style="color: #339933;">=&gt;</span> Add_Slashes<span style="color: #339933;">::</span><span style="color: #004000;">usage</span><span style="color: #000;">&#40;</span><span style="color: #000;">&#41;</span>
<span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #000000; font-weight: bold;">class</span> Add_Slashes
<span style="color: #000;">&#123;</span>
	<span style="color: #000000; font-weight: bold;">function</span> Add_Slashes<span style="color: #000;">&#40;</span><span style="color: #000;">&#41;</span>
	<span style="color: #000;">&#123;</span>
		<span style="color: #000000; font-weight: bold;">global</span> <span style="color: #000088;">$TMPL</span><span style="color: #339933;">;</span>
		<span style="color: #000088;">$this</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">return_data</span> <span style="color: #339933;">=</span> <span style="color: #990000;">addslashes</span><span style="color: #000;">&#40;</span><span style="color: #000088;">$TMPL</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">tagdata</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
        <span style="color: #000;">&#125;</span> 
&nbsp;
	<span style="color: #000000; font-weight: bold;">function</span> usage<span style="color: #000;">&#40;</span><span style="color: #000;">&#41;</span>
	<span style="color: #000;">&#123;</span>
		<span style="color: #22f;">return</span> <span style="color: #0000ff;">&quot;This is really just a wrapper for PHP's add_slashes function:
http://php.net/manual/en/function.addslashes.php
&nbsp;
{exp:add_slashes}
O'Reilly
{/exp:add_slashes}
returns: O\'Reilly
&nbsp;
&quot;</span><span style="color: #339933;">;</span>
	<span style="color: #000;">&#125;</span> 
&nbsp;
<span style="color: #000;">&#125;</span></pre></div></div>

<p>Now, this example was used using Expression Engine 1.6.9 so the process might not work for the upcoming 2.0 (I haven&#8217;t looked into that version just yet). It also doesn&#8217;t look like EllisLabs is accepting any new submissions to their plugin library so if you&#8217;re hoping to distribute your plugin prepare to do it solo and without any help from them.</p>
<p>Still, an easy enough process that any custom functionality you may need for an Expression Engine site should be trivial to achieve.  </p>
<img src="http://feeds.feedburner.com/~r/MadeOfEverythingYoureNot/~4/UasHKq8ns84" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.ericlamb.net/2010/06/create-expression-engine-plugin/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.ericlamb.net/2010/06/create-expression-engine-plugin/</feedburner:origLink></item>
		<item>
		<title>hResume hKit Profile</title>
		<link>http://feedproxy.google.com/~r/MadeOfEverythingYoureNot/~3/CHgx18SBU14/</link>
		<comments>http://blog.ericlamb.net/2010/06/hresume-hkit-profile/#comments</comments>
		<pubDate>Thu, 03 Jun 2010 00:14:39 +0000</pubDate>
		<dc:creator>Eric Lamb</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[career]]></category>
		<category><![CDATA[hresume]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://blog.ericlamb.net/?p=2807</guid>
		<description><![CDATA[While working on Wp-hResume (a neat plugin for adding any hResume encoded resume to a WordPress site) I needed to make a decision. The strategy I was working on hinged on the choice between either using brute force regular expressions to parse the profile page for a single site (like the competition)  or to write [...]]]></description>
			<content:encoded><![CDATA[<p>While working on <a title="Introducing WP-hResume" href="http://blog.ericlamb.net/2010/01/introducing-wp-hresume/" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2F2010%2F01%2Fintroducing-wp-hresume%2F','Introducing+WP-hResume')" target="_self">Wp-hResume</a> (a neat plugin for adding <em>any</em> <a title="hResume" href="http://en.wikipedia.org/wiki/HResume" onclick="return TrackClick('http%3A%2F%2Fen.wikipedia.org%2Fwiki%2FHResume','hResume')" target="_blank">hResume</a> encoded resume to a WordPress site) I needed to make a decision. The strategy I was working on hinged on the choice between either  using brute force regular expressions to parse the profile page for a  single site (like the competition)  or to write the missing hResume profile for the <a title="hKit" href="http://code.google.com/p/hkit/" onclick="return TrackClick('http%3A%2F%2Fcode.google.com%2Fp%2Fhkit%2F','hKit')" target="_blank">hKit  Microformat Framework</a>.</p>
<div id="attachment_3254" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/Redundant.gif" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2FRedundant.gif','hKit+hResume')"><img class="size-medium wp-image-3254" title="hKit hResume " src="http://blog.ericlamb.net/wp-content/uploads/2010/05/Redundant-300x205.gif" alt="hKit hResume" width="300" height="205" /></a><p class="wp-caption-text">hKit hResume </p></div>
<p>The way I saw it, with regular expressions I could only build a plugin that would only work with a single site; whereas with an hKit profile the plugin could, in theory, work with any hResume encoded site. So, clearly, an hKit profile was the best option.</p>
<p>The only problem was that there isn&#8217;t any documentation on how to actually create a profile for hKit. I don&#8217;t want to go into detail on it, and to be honest I don&#8217;t really remember all the details so suffice it to say that brute forcing this thing sucked. Donkey balls. It took forever and the steps needed to build a profile used a methodology I wasn&#8217;t familiar with. But, after a long night of tequila I did end up putting it all together though and it works pretty nicely.</p>
<p>First though, here&#8217;s how hKit works for pulling in a microformatted URL:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span> 
<span style="color: #22f;">include</span><span style="color: #000;">&#40;</span><span style="color: #0000ff;">'hkit.class.php'</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$hKit</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> hKit<span style="color: #339933;">;</span>
<span style="color: #000088;">$result</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$hKit</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">getByURL</span><span style="color: #000;">&#40;</span><span style="color: #0000ff;">'hcard'</span><span style="color: #339933;">,</span> <span style="color: #0000ff;">'http://microformats.org/'</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>Pretty obvious stuff; give it a URL, set the type of encoding expected (this time it&#8217;s hcard) and it gives back an array with all the goodies. </p>
<p>To work with the new profile you have to place the profile file in the same directory as hkit.class.php. You can download the profile along with the latest version of <a href="http://blog.ericlamb.net/wp-content/uploads/2010/06/hkit.zip" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F06%2Fhkit.zip','hKit+here')">hKit here</a>.</p>
<p>The concept is the same with the new profile:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
<span style="color: #22f;">include</span><span style="color: #000;">&#40;</span><span style="color: #0000ff;">'hkit.class.php'</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$h</span> <span style="color: #339933;">=</span> <span style="color: #000000; font-weight: bold;">new</span> hKit<span style="color: #339933;">;</span>	
<span style="color: #000088;">$url</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'http://www.linkedin.com/in/mithra62'</span><span style="color: #339933;">;</span>
<span style="color: #000088;">$h</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">tidy_mode</span> <span style="color: #339933;">=</span> <span style="color: #0000ff;">'proxy'</span><span style="color: #339933;">;</span> <span style="color: #666666; font-style: italic;">// 'proxy', 'exec', 'php' or 'none'</span>
<span style="color: #000088;">$result</span> <span style="color: #339933;">=</span> <span style="color: #000088;">$h</span><span style="color: #339933;">-&gt;</span><span style="color: #004000;">getByURL</span><span style="color: #000;">&#40;</span><span style="color: #0000ff;">'hresume'</span><span style="color: #339933;">,</span> <span style="color: #000088;">$url</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #990000;">print_r</span><span style="color: #000;">&#40;</span><span style="color: #000088;">$result</span><span style="color: #339933;">,</span> <span style="color: #cc66cc;">1</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>The above will pull my hResume encoded info from my LinkedIn profile. Same as the original hcard example. Easy like your sister.</p>
<p>Now go forth and start parsing hresume encoded URLs <img src='http://blog.ericlamb.net/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<img src="http://feeds.feedburner.com/~r/MadeOfEverythingYoureNot/~4/CHgx18SBU14" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.ericlamb.net/2010/06/hresume-hkit-profile/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		<feedburner:origLink>http://blog.ericlamb.net/2010/06/hresume-hkit-profile/</feedburner:origLink></item>
		<item>
		<title>A Closer Look At Avactis</title>
		<link>http://feedproxy.google.com/~r/MadeOfEverythingYoureNot/~3/CQWOEGYStxs/</link>
		<comments>http://blog.ericlamb.net/2010/05/a-closer-look-at-avactis/#comments</comments>
		<pubDate>Mon, 31 May 2010 17:14:14 +0000</pubDate>
		<dc:creator>Eric Lamb</dc:creator>
				<category><![CDATA[Brain Dump]]></category>
		<category><![CDATA[Code]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[Rant]]></category>
		<category><![CDATA[Avactis]]></category>
		<category><![CDATA[e-commerce]]></category>
		<category><![CDATA[php]]></category>

		<guid isPermaLink="false">http://blog.ericlamb.net/?p=3186</guid>
		<description><![CDATA[Avactis is another in a long line of e-commerce web applications written in php (similar to OpenCart and PrestaCart), this one a little different in that Avactis has different versions, each with different features, depending on how much you&#8217;re willing to spend. Avactis is a full featured product with all the bells and whistles any [...]]]></description>
			<content:encoded><![CDATA[<p><a title="Avactis" href="http://www.avactis.com/" onclick="return TrackClick('http%3A%2F%2Fwww.avactis.com%2F','Avactis')" target="_blank">Avactis</a> is another in a long line of e-commerce web applications written in php (similar to <a href="http://blog.ericlamb.net/2010/05/should-we-use-opencart/" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2F2010%2F05%2Fshould-we-use-opencart%2F','OpenCart')">OpenCart</a> and <a href="http://blog.ericlamb.net/2010/05/should-we-use-prestashop/" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2F2010%2F05%2Fshould-we-use-prestashop%2F','PrestaCart')">PrestaCart</a>), this one a little different in that Avactis has different versions, each with different features, depending on how much you&#8217;re willing to spend. Avactis is a full featured product with all the bells and whistles any ambitious store would need (and then some more features stacked on top for good measure) combined with a very php like integration methodology. Unfortunately, the dated administration interface combined with a lack of a plugin architecture and theme community really holds it back from the awesome bar.</p>
<div id="attachment_3222" class="wp-caption aligncenter" style="width: 230px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/Avactis-logo.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2FAvactis-logo.png','Avactis')"><img class="size-full wp-image-3222" title="Avactis" src="http://blog.ericlamb.net/wp-content/uploads/2010/05/Avactis-logo.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2FAvactis-logo.png','Avactis')" alt="Avactis" width="220" height="79" /></a><p class="wp-caption-text">Avactis</p></div>
<p>For the uninitiated, Avactis is created and maintained by Pentasoft Corp; oddly, there&#8217;s no website for the parent company so take that for what you will. As mentioned, Avactis is based on a pay model though it&#8217;s way more upfront about it than PrestaCart and, while the free version is missing some features, the source is available for modifications. Not too bad in my opinion; at least the more cash strapped shops can still play if they want to.</p>
<p>The different versions of Avactis are Free, Owned ($199), Monthly Leased ($19.95 a month) and White Label ($299) each with their own <a title="Compare Avactis Shopping Cart Editions" href="http://www.avactis.com/compare_avactis_editions.php" onclick="return TrackClick('http%3A%2F%2Fwww.avactis.com%2Fcompare_avactis_editions.php','Compare+Avactis+Shopping+Cart+Editions')" target="_blank">features and options</a>. Most notably the Free version doesn&#8217;t include any (useful) payment modules (Authorize.net anyone?), coupon module, data export and import, quantity discounts or search engine friendly URLs out of the box. They do offer <a title="Discounts for Web developers" href="https://www.avactis.com/ads/shopping-cart-camp1.php" onclick="return TrackClick('https%3A%2F%2Fwww.avactis.com%2Fads%2Fshopping-cart-camp1.php','Discounts+for+Web+developers')" target="_blank">discounts for web developers</a> though (at least 50% and they say up to 100%), and the complete source is available without obfuscation, so at least those functions that are needed can be added which can really ease the pain of <em>paying</em> for the thing in my opinion.</p>
<p>As expected, Avactis has the ability for custom <a title="Avactis Themes" href="http://www.avactis.com/avactis_themes.php" onclick="return TrackClick('http%3A%2F%2Fwww.avactis.com%2Favactis_themes.php','Avactis+Themes')" target="_blank">themes</a> though I&#8217;m disappointed to see that there doesn&#8217;t appear to be any theme community in existence (compared to other cart software packages). The reasoning behind this is probably because Avactis bills itself as being &#8220;easy integration with an existing website  thanks to unique Avactis tag technology&#8221;. And by unique they mean including a php file and calling php function snippets. I&#8217;m all for marketing hype but wtf is that?!? Here&#8217;s an <a title="Five Easy Steps..." href="http://docs.avactis.com/190/index.html?five_easy_steps_to_integrate.htm" onclick="return TrackClick('http%3A%2F%2Fdocs.avactis.com%2F190%2Findex.html%3Ffive_easy_steps_to_integrate.htm','Five+Easy+Steps...')" target="_blank">example</a>:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span> <span style="color: #22f;">include</span><span style="color: #000;">&#40;</span><span style="color: #0000ff;">'init.php'</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
<span style="color: #000000; font-weight: bold;">&lt;?php</span> NavigationBar<span style="color: #000;">&#40;</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
<span style="color: #000000; font-weight: bold;">&lt;?php</span> Breadcrumb<span style="color: #000;">&#40;</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span>
<span style="color: #000000; font-weight: bold;">&lt;?php</span> ProductList<span style="color: #000;">&#40;</span><span style="color: #000;">&#41;</span><span style="color: #339933;">;</span> <span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>It&#8217;s called php and EVERY php site does this Avactis not just you. Essentially though, this isn&#8217;t a bad strategy and, in fact, is definitely a strength especially without all the hyperbole. Obviously, Avactis can stand alone and doesn&#8217;t <em>need</em> to be integrated into a separate site but it&#8217;s a good idea to allow easy integration into existing sites. </p>
<div id="attachment_3217" class="wp-caption aligncenter" style="width: 200px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/Avactis-PHP-shopping-cart-software.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2FAvactis-PHP-shopping-cart-software.png','Avactis+PHP+shopping+cart+software')"><img class="size-medium wp-image-3217" title="Avactis PHP shopping cart software" src="http://blog.ericlamb.net/wp-content/uploads/2010/05/Avactis-PHP-shopping-cart-software-190x300.png" alt="Avactis PHP shopping cart software" width="190" height="300" /></a><p class="wp-caption-text">Avactis PHP shopping cart software</p></div>
<p>Avactis is packed with all the features any online store would want; content management system, coupon and discount mechanisms, order and customer management, packing slip builder to name a few. Each feature is also highly customizable and usually includes a plethora of options and settings; nice if you build complex product build outs or specific functionality. On the other hand though, this amount of features and customization comes at a cost in terms of ease of use, work flow and a lacking user friendly experience.</p>
<p>The administration interface for Avactis is a nightmare mess of pop-up windows, tabs and accordion widgets. Slick is not a word I would use to describe the experience. Functional or crappy or painful or eyebleedingworstinterfaceeverpleasekillmefortheloveofgod!; those are better words to describe it. </p>
<p>There&#8217;s inconsistencies all over the place; for example while editing a product the help widgets will open another pop-up window (sigh&#8230;) yet in the main menu hovering over a link will display a tool tip and in the installation process the help widgets are all inline divs. </p>
<div id="attachment_3242" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/activis-admin.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2Factivis-admin.png','Avactis+Admin+Popups')"><img src="http://blog.ericlamb.net/wp-content/uploads/2010/05/activis-admin-300x168.png" alt="Avactis Admin Popups" title="Avactis Admin Popups" width="300" height="168" class="size-medium wp-image-3242" /></a><p class="wp-caption-text">Avactis Admin Popups</p></div>
<p>Going through the code yields such <a href="http://thedailywtf.com/Series/CodeSOD.aspx" onclick="return TrackClick('http%3A%2F%2Fthedailywtf.com%2FSeries%2FCodeSOD.aspx','codesod')" target="_blank" title="codesod">codesod</a> qualifiers as the below:</p>

<div class="wp_syntax"><div class="code"><pre class="php" style="font-family:monospace;"><span style="color: #000000; font-weight: bold;">&lt;?php</span>
    <span style="color: #009933; font-style: italic;">/**
     * Defines the possibility of uploading images by file type.
     *
     * @param $file The array consists of the $_FILES variable, for
     * the current file.
     * @return boolean
     */</span>
    <span style="color: #000000; font-weight: bold;">function</span> isAllowedImageType<span style="color: #000;">&#40;</span><span style="color: #000088;">$file</span><span style="color: #000;">&#41;</span>
    <span style="color: #000;">&#123;</span>
<span style="color: #666666; font-style: italic;">/*        $type = _ml_strtolower($file['type']);
        switch ($type)
        {
            case 'image/gif':
            case 'image/jpeg':
            case 'image/jpg':
            case 'image/jpe':
            case 'image/jfif':
            case 'image/pjpeg':
            case 'image/pjp':
            case 'image/png':
            case 'image/x-png':
                return true;
            default:
                return false;
        }
*/</span>
        <span style="color: #22f;">return</span> <span style="color: #009900; font-weight: bold;">true</span><span style="color: #339933;">;</span>
    <span style="color: #000;">&#125;</span>
<span style="color: #000000; font-weight: bold;">?&gt;</span></pre></div></div>

<p>If that doesn&#8217;t make any sense to you suffice it to say that the above function is supposed to verify that an image&#8217;s mime type matches the list; unfortunately though, the function is, what we call &#8220;commented out&#8221; and will not be executed. All files sent to the function will validate as true so, essentially, any file type can be uploaded. While it&#8217;s entirely possible this is an old function that was replaced with something <em>useful</em>, and it should be noted that I never found any calls to that function (but I really didn&#8217;t look too hard), the fact that it&#8217;s still in the code-base speaks volumes, to me, about the project maintenance at the very least.  </p>
<p>On top of that Avactis has one of the most wasteful and useless installation processes I&#8217;ve ever seen. Initially, Avactis ships with a very minimal file set that includes a 15 mega byte (MB) file whose sole purpose is to contain all additional files in a gzipped and base64 encoded string. The sole purpose of this is to allow Avactis to programmatically write all source files to the file system during installation. For the life of me I can&#8217;t imagine what functional requirement precipitated this design decision. Considering the complexity added to the development cycle this would cause it makes no sense to me; I&#8217;m at a loss. I could be missing something though; you never know it may have a really sick benefit that I&#8217;m just not privy to. </p>
<p>Are any of those &#8220;issues&#8221; at all relevant? Not the function and not the installation process. Those are subjective issues that may only matter to me; it&#8217;s <a href="http://encarta.msn.com/dictionary_561535560/armchair_quarterback.html" onclick="return TrackClick('http%3A%2F%2Fencarta.msn.com%2Fdictionary_561535560%2Farmchair_quarterback.html','Armchair+Quarterback')" target="_blank" title="Armchair Quarterback">armchair quarterbacking</a> at it&#8217;s finest (if I do say so myself). For everything else, well, that obviously depends on the specific needs of the project. For my needs it&#8217;s a pass simply because my clients care about the interface and Avactis looks like it hasn&#8217;t been updated since 2002 (at least). </p>
<p>So, while Avactis is a nice program with all of the features any store would ever need I personally feel that it&#8217;s not ready for my project. </p>
<img src="http://feeds.feedburner.com/~r/MadeOfEverythingYoureNot/~4/CQWOEGYStxs" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.ericlamb.net/2010/05/a-closer-look-at-avactis/feed/</wfw:commentRss>
		<slash:comments>4</slash:comments>
		<feedburner:origLink>http://blog.ericlamb.net/2010/05/a-closer-look-at-avactis/</feedburner:origLink></item>
		<item>
		<title>Should We Use OpenCart?</title>
		<link>http://feedproxy.google.com/~r/MadeOfEverythingYoureNot/~3/8aOkLip1XFM/</link>
		<comments>http://blog.ericlamb.net/2010/05/should-we-use-opencart/#comments</comments>
		<pubDate>Tue, 25 May 2010 07:00:51 +0000</pubDate>
		<dc:creator>Eric Lamb</dc:creator>
				<category><![CDATA[Brain Dump]]></category>
		<category><![CDATA[Programming]]></category>
		<category><![CDATA[e-commerce]]></category>
		<category><![CDATA[opencart]]></category>

		<guid isPermaLink="false">http://blog.ericlamb.net/?p=3184</guid>
		<description><![CDATA[As a continuation of my research into choosing an appropriate shopping cart application for an upcoming project I&#8217;m working on I chose to review OpenCart this time. To be honest, I hadn&#8217;t even heard of OpenCart until one of the comments from the last post turned me onto it but after reviewing it I am [...]]]></description>
			<content:encoded><![CDATA[<p>As a continuation of my research into <a title="Should We Use PrestaShop?" href="http://blog.ericlamb.net/2010/05/should-we-use-prestashop/" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2F2010%2F05%2Fshould-we-use-prestashop%2F','Should+We+Use+PrestaShop%3F')" target="_self">choosing an appropriate shopping cart application</a> for an upcoming project I&#8217;m working on I chose to review <a title="OpenCart" href="http://www.opencart.com/" onclick="return TrackClick('http%3A%2F%2Fwww.opencart.com%2F','OpenCart')" target="_blank">OpenCart</a> this time. To be honest, I hadn&#8217;t even heard of OpenCart until one of the comments from the last post turned me onto it but after reviewing it I am glad I did.</p>
<div id="attachment_3193" class="wp-caption aligncenter" style="width: 278px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/opencart-logo.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2Fopencart-logo.png','opencart-logo')"><img class="size-full wp-image-3193" title="opencart-logo" src="http://blog.ericlamb.net/wp-content/uploads/2010/05/opencart-logo.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2Fopencart-logo.png','opencart-logo')" alt="opencart-logo" width="268" height="50" /></a><p class="wp-caption-text">opencart-logo</p></div>
<p>As mentioned above, OpenCart is another e-commerce platform useful for setting up an online storefront. OpenCart is released under the <a title="GNU General Public License version 3 (GPLv3)" href="http://www.gnu.org/licenses/gpl.html" onclick="return TrackClick('http%3A%2F%2Fwww.gnu.org%2Flicenses%2Fgpl.html','GNU+General+Public+License+version+3+%28GPLv3%29')" target="_blank">GNU General Public License version 3 (GPLv3)</a> which means it&#8217;s freely available for anyone to use and since OpenCart is written in php it&#8217;s right in my wheel house. The main developer of OpenCart is Daniel Kerr who, from what I can gather, is over in Great Britain but not the <a title="Daniel Kerr" href="http://en.wikipedia.org/wiki/Daniel_Kerr" onclick="return TrackClick('http%3A%2F%2Fen.wikipedia.org%2Fwiki%2FDaniel_Kerr','Daniel+Kerr')" target="_blank">Australian rules footballer</a> (in case there was some confusion from any Aussies).</p>
<p>Anywho, OpenCart has lot of good features available out of the box with my favorites being the Backup Manager,  User Groups, really nice localization (l18n) and internationalization  (i18n) options, support for multiple stores and a slick reporting  overview. OpenCart also has the one feature I personally love from any and all e-commerce packages; Guest Checkouts. Personally, when I&#8217;m  buying something from an online store that&#8217;s not a 500 pound gorilla  like Amazon or Best Buy I hate signing up for an account. Guest checkout  is the shit.</p>
<p>The code is really well structured and thought out; it uses a nice  implementation of the MVC pattern which made things ridiculously easy to  walk through and find out what was going on under the hood. OpenCart appears to be using a home grown MVC framework, which, while, in my opinion a little unnecessary,  isn&#8217;t at all a big deal. Unfortunately, the code appears to be open to <a title="Cross Site Request Forgery" href="http://en.wikipedia.org/wiki/Cross-site_request_forgery" onclick="return TrackClick('http%3A%2F%2Fen.wikipedia.org%2Fwiki%2FCross-site_request_forgery','Cross+Site+Request+Forgery')" target="_blank">Cross Site Request Forgery</a> (CSRF) attacks and other security issues. More on this in a minute.</p>
<p>The OpenCart administration module is attractive and laid out logically. Everything is ready and available in such a way that most people with experience working with administration panels would feel right at home. It should be noted though that the administration panel will NOT work in Internet Explorer 6.</p>
<div id="attachment_3197" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/OpenCart-Dashboard.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2FOpenCart-Dashboard.png','OpenCart+Dashboard')"><img class="size-medium wp-image-3197" title="OpenCart Dashboard" src="http://blog.ericlamb.net/wp-content/uploads/2010/05/OpenCart-Dashboard-300x158.png" alt="OpenCart Dashboard" width="300" height="158" /></a><p class="wp-caption-text">OpenCart Dashboard</p></div>
<p>Naturally, OpenCart also ships with the ability to have custom themes and the default theme that ships with OpenCart is quite attractive too. After reviewing the <a title="Create OpenCart Themes" href="http://www.opencart.com/index.php?route=documentation/documentation&amp;path=43_44" onclick="return TrackClick('http%3A%2F%2Fwww.opencart.com%2Findex.php%3Froute%3Ddocumentation%2Fdocumentation%26amp%3Bpath%3D43_44','Create+OpenCart+Themes')" target="_blank">procedure</a> for creating themes though I have to say that I&#8217;m not even a little impressed in how themes are supposed to be created; they appear, in my opinion, to be overly complicated, a little convoluted and deviates from the traditional manner used with countless other open source projects.</p>
<div id="attachment_3199" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/OpenCart-Store.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2FOpenCart-Store.png','OpenCart+Store')"><img class="size-medium wp-image-3199" title="OpenCart Store" src="http://blog.ericlamb.net/wp-content/uploads/2010/05/OpenCart-Store-300x248.png" alt="OpenCart Store" width="300" height="248" /></a><p class="wp-caption-text">OpenCart Store</p></div>
<p>OpenCart has a basic module system though it isn&#8217;t what, in my experience, should be considered a module system; in OpenCart a module is more of a sidebar widget. A small distinction to be sure and not really an issue; more of an inconvenience of nomenclature than anything else but something that drives me nuts (can&#8217;t we all agree on what these terms mean already?).</p>
<p>There&#8217;s also a lot of manual intervention needed when configuring the system. Want to add a module? FTP the module, go to the module section of the admin, click install, click edit and fill out the form (be sure to enable the module too). Want to turn on search engine friendly URLs? Rename the file .htaccess.txt to .htaccess (through FTP or similar) then go to the administration panel, then to the settings area to enable. Very anti user friendly in my opinion.</p>
<p>There are other issues with OpenCart, like the flow for adding images to a product being pretty convoluted, but those are all small in the grand scheme (pretty much all my gripes can be, rightfully, dismissed as design decisions I don&#8217;t agree with). Fair enough. What isn&#8217;t acceptable is the complete lack of respect the developer has for security in OpenCart or the developers who try to help out in general. This, I&#8217;m afraid, is a deal breaker.</p>
<p>May 2010 was actually a pretty fortuitous time for me to research OpenCart; as soon as I began looking into the program I started seeing some discussion on OpenCart which lead me to a forum post on the official OpenCart forums. Another developer had some suggestions on how to improve the style and conventions of OpenCart and, well, <a title="General feedback and suggenstions about OpenCart" href="http://forum.opencart.com/viewtopic.php?p=72582#p72582" onclick="return TrackClick('http%3A%2F%2Fforum.opencart.com%2Fviewtopic.php%3Fp%3D72582%23p72582','General+feedback+and+suggenstions+about+OpenCart')" target="_blank">Daniel really showed his ass</a>.</p>
<p>Then, not a week later, I see on that there&#8217;s another war going on between Daniel and a developer who found some pretty nasty CSRF issues. Again, <a title="OpenCart CSRF Vulnerability" href="http://blog.visionsource.org/2010/01/28/opencart-csrf-vulnerability/" onclick="return TrackClick('http%3A%2F%2Fblog.visionsource.org%2F2010%2F01%2F28%2Fopencart-csrf-vulnerability%2F','OpenCart+CSRF+Vulnerability')" target="_blank">Daniel showed his ass</a> (along with a good helping of ignorance mixed with arrogance this time) with nothing being resolved.</p>
<p>This was truly the breaking point for me. Why in the world would I ever use software written by someone who, when confronted with the issues, acts like nothing&#8217;s wrong? Nope. I have people relying on me to make choices that won&#8217;t, you know, ruin their business and OpenCart, for all it&#8217;s bells and whistles and nice code and pretty administration panel, is a horrible platform because the developer <em>refuses</em> to do anything about issues when presented with them.</p>
<img src="http://feeds.feedburner.com/~r/MadeOfEverythingYoureNot/~4/8aOkLip1XFM" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.ericlamb.net/2010/05/should-we-use-opencart/feed/</wfw:commentRss>
		<slash:comments>39</slash:comments>
		<feedburner:origLink>http://blog.ericlamb.net/2010/05/should-we-use-opencart/</feedburner:origLink></item>
		<item>
		<title>Wp-Click-Track 0.7.1</title>
		<link>http://feedproxy.google.com/~r/MadeOfEverythingYoureNot/~3/_c7gHiGG46o/</link>
		<comments>http://blog.ericlamb.net/2010/05/wp-click-track-0-7-1/#comments</comments>
		<pubDate>Thu, 20 May 2010 07:00:44 +0000</pubDate>
		<dc:creator>Eric Lamb</dc:creator>
				<category><![CDATA[Code]]></category>
		<category><![CDATA[wordpress]]></category>
		<category><![CDATA[wordpress plugin]]></category>
		<category><![CDATA[wp-click-track]]></category>

		<guid isPermaLink="false">http://blog.ericlamb.net/?p=3166</guid>
		<description><![CDATA[Dreamhost is slandering me! They think I suck and have no problem telling people as much. Seriously; I write bad code by them. How do I know? Because Chris Duke over at AppModo told me so. Problem is, Dreamhost was 100% right. Yup; I fucked up. On Monday I got an email from Chris asking [...]]]></description>
			<content:encoded><![CDATA[<p><a title="Dreamhost" href="http://www.dreamhost.com/" onclick="return TrackClick('http%3A%2F%2Fwww.dreamhost.com%2F','Dreamhost')" target="_blank">Dreamhost</a> is slandering me! They think I suck and have no problem telling people as much. Seriously; I write bad code by them. How do I know? Because Chris Duke over at <a title="AppModo" href="http://appmodo.com/" onclick="return TrackClick('http%3A%2F%2Fappmodo.com%2F','AppModo')" target="_blank">AppModo</a> told me so. Problem is, Dreamhost was 100% right. Yup; I fucked up.</p>
<div id="attachment_3167" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/wp-click-track-0.7.1.jpg" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2Fwp-click-track-0.7.1.jpg','Wp-Click-Track+0.7.1')"><img class="size-medium wp-image-3167" title="Wp-Click-Track 0.7.1" src="http://blog.ericlamb.net/wp-content/uploads/2010/05/wp-click-track-0.7.1-300x168.jpg" alt="Wp-Click-Track 0.7.1" width="300" height="168" /></a><p class="wp-caption-text">Wp-Click-Track 0.7.1</p></div>
<p>On Monday I got an email from Chris asking for some help with one of the WordPress plugins I wrote; wp-click-track. Chris was cool enough to let me post the message he received from Dreamhost:</p>
<blockquote><p>Hello,</p>
<p>I&#8217;m writing you about your database &#8220;appmodo&#8221;, please write me back as soon as possible.  There seems to be a plugin you are running that is poorly coded (missing table joins) and this 1300+ second query that it is running is causing high server load spikes. If this plugin is not fixed, or disabled, and it causes server problems, we may need to disable the wp_tracking_clicks and wp_tracking_links tables.  You can write me at justin@dreamhost.com.</p>
<p>The problem queries:</p>
<p># Query_time: 2181  Lock_time: 1115  Rows_sent: 1  Rows_examined: 38703 use appmodo;</p>

<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;"><span style="color: #22f;">SELECT</span> date_format<span style="color: #000;">&#40;</span>click_date<span style="color: #66cc66;">,</span><span style="color: #ff0000;">&quot;%Y-%m-%d&quot;</span><span style="color: #000;">&#41;</span> <span style="color: #22f;">AS</span> first_click<span style="color: #66cc66;">,</span>
date_format<span style="color: #000;">&#40;</span>click_date<span style="color: #66cc66;">,</span><span style="color: #ff0000;">&quot;%j&quot;</span><span style="color: #000;">&#41;</span> <span style="color: #22f;">AS</span> day_of_year <span style="color: #22f;">FROM</span> wp_tracking_clicks tc<span style="color: #66cc66;">,</span>
wp_tracking_links tl <span style="color: #22f;">WHERE</span> tc<span style="color: #66cc66;">.</span>click_id !<span style="color: #66cc66;">=</span> <span style="color: #ff0000;">'0'</span>  <span style="color: #22f;">GROUP</span> <span style="color: #22f;">BY</span> first_click <span style="color: #22f;">ORDER</span>
<span style="color: #22f;">BY</span> first_click <span style="color: #22f;">DESC</span> <span style="color: #22f;">LIMIT</span> <span style="color: #cc66cc;">1</span>;</pre></div></div>

<p># Query_time: 1995  Lock_time: 924  Rows_sent: 1  Rows_examined: 38703 use appmodo;</p>

<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;"><span style="color: #22f;">SELECT</span> date_format<span style="color: #000;">&#40;</span>click_date<span style="color: #66cc66;">,</span><span style="color: #ff0000;">&quot;%Y-%m-%d&quot;</span><span style="color: #000;">&#41;</span> <span style="color: #22f;">AS</span> first_click<span style="color: #66cc66;">,</span>
date_format<span style="color: #000;">&#40;</span>click_date<span style="color: #66cc66;">,</span><span style="color: #ff0000;">&quot;%j&quot;</span><span style="color: #000;">&#41;</span> <span style="color: #22f;">AS</span> day_of_year <span style="color: #22f;">FROM</span> wp_tracking_clicks tc<span style="color: #66cc66;">,</span>
wp_tracking_links tl <span style="color: #22f;">WHERE</span> tc<span style="color: #66cc66;">.</span>click_id !<span style="color: #66cc66;">=</span> <span style="color: #ff0000;">'0'</span>  <span style="color: #22f;">GROUP</span> <span style="color: #22f;">BY</span> first_click <span style="color: #22f;">ORDER</span>
<span style="color: #22f;">BY</span> first_click <span style="color: #22f;">DESC</span> <span style="color: #22f;">LIMIT</span> <span style="color: #cc66cc;">1</span>;</pre></div></div>

<p># Query_time: 1387  Lock_time: 309  Rows_sent: 1  Rows_examined: 38703 use appmodo;</p>

<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;"><span style="color: #22f;">SELECT</span> date_format<span style="color: #000;">&#40;</span>click_date<span style="color: #66cc66;">,</span><span style="color: #ff0000;">&quot;%Y-%m-%d&quot;</span><span style="color: #000;">&#41;</span> <span style="color: #22f;">AS</span> first_click<span style="color: #66cc66;">,</span>
date_format<span style="color: #000;">&#40;</span>click_date<span style="color: #66cc66;">,</span><span style="color: #ff0000;">&quot;%j&quot;</span><span style="color: #000;">&#41;</span> <span style="color: #22f;">AS</span> day_of_year <span style="color: #22f;">FROM</span> wp_tracking_clicks tc<span style="color: #66cc66;">,</span>
wp_tracking_links tl <span style="color: #22f;">WHERE</span> tc<span style="color: #66cc66;">.</span>click_id !<span style="color: #66cc66;">=</span> <span style="color: #ff0000;">'0'</span>  <span style="color: #22f;">GROUP</span> <span style="color: #22f;">BY</span> first_click <span style="color: #22f;">ORDER</span>
<span style="color: #22f;">BY</span> first_click <span style="color: #22f;">DESC</span> <span style="color: #22f;">LIMIT</span> <span style="color: #cc66cc;">1</span>;</pre></div></div>

<p># Query_time: 2016  Lock_time: 930  Rows_sent: 1  Rows_examined: 38703 use appmodo;</p>

<div class="wp_syntax"><div class="code"><pre class="sql" style="font-family:monospace;"><span style="color: #22f;">SELECT</span> date_format<span style="color: #000;">&#40;</span>click_date<span style="color: #66cc66;">,</span><span style="color: #ff0000;">&quot;%Y-%m-%d&quot;</span><span style="color: #000;">&#41;</span> <span style="color: #22f;">AS</span> first_click<span style="color: #66cc66;">,</span>
date_format<span style="color: #000;">&#40;</span>click_date<span style="color: #66cc66;">,</span><span style="color: #ff0000;">&quot;%j&quot;</span><span style="color: #000;">&#41;</span> <span style="color: #22f;">AS</span> day_of_year <span style="color: #22f;">FROM</span> wp_tracking_clicks tc<span style="color: #66cc66;">,</span>
wp_tracking_links tl <span style="color: #22f;">WHERE</span> tc<span style="color: #66cc66;">.</span>click_id !<span style="color: #66cc66;">=</span> <span style="color: #ff0000;">'0'</span>  <span style="color: #22f;">GROUP</span> <span style="color: #22f;">BY</span> first_click <span style="color: #22f;">ORDER</span>
<span style="color: #22f;">BY</span> first_click <span style="color: #22f;">DESC</span> <span style="color: #22f;">LIMIT</span> <span style="color: #cc66cc;">1</span>;</pre></div></div>

<p>Thanks!<br />
Justin K</p></blockquote>
<p>Justin did a nice job highlighting what the issue was; I didn&#8217;t join the tables together so it would take a really long time to complete the scans if there were a lot of rows in the tables. Another reason to always develop with <a title="Everything Is Fast For Small n" href="http://www.codinghorror.com/blog/2007/09/everything-is-fast-for-small-n.html" onclick="return TrackClick('http%3A%2F%2Fwww.codinghorror.com%2Fblog%2F2007%2F09%2Feverything-is-fast-for-small-n.html','Everything+Is+Fast+For+Small+n')" target="_blank">large data</a> sets; something I obviously didn&#8217;t do with wp-click-track.</p>
<blockquote><p>Your application is useful and popular. Your users love it. Your users love you. But over the next week, something curious happens. As people use the application, it gets progressively slower and slower. Soon, the complaints start filtering in.  Within a few weeks, the app is well-neigh unusable due to all the insufferable delays it subjects users to&#8211; and <a title="Designing for Informavores, or, Why Users Behave Like Animals Online" href="http://www.codinghorror.com/blog/archives/000882.html" onclick="return TrackClick('http%3A%2F%2Fwww.codinghorror.com%2Fblog%2Farchives%2F000882.html','Designing+for+Informavores%2C+or%2C+Why+Users+Behave+Like+Animals+Online')" target="_blank">your users turn on you</a>.</p></blockquote>
<p>Anyway, there was no excuse for that; this was shoddy on my part. The only explanation I have is poor quality on my part. </p>
<p>This particular bug affected the line chart on the admin dashboard. Ever wonder why that particular graph took <em>forever</em> to load? Yup, that&#8217;s why.</p>
<p>What&#8217;s funny, to me at least, was that I had already fixed this particular issue; I just hadn&#8217;t released it yet. This particular bug was planned to be released with 0.8 but 0.8 is taking longer to complete than I initially thought it would. So the bug fix languished and sat there. Unreleased.</p>
<p>So yeah, wp-click-track 0.7.1. It&#8217;s a good release to get.</p>
<img src="http://feeds.feedburner.com/~r/MadeOfEverythingYoureNot/~4/_c7gHiGG46o" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.ericlamb.net/2010/05/wp-click-track-0-7-1/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://blog.ericlamb.net/2010/05/wp-click-track-0-7-1/</feedburner:origLink></item>
		<item>
		<title>Should We Use PrestaShop?</title>
		<link>http://feedproxy.google.com/~r/MadeOfEverythingYoureNot/~3/HgJtlXayS7U/</link>
		<comments>http://blog.ericlamb.net/2010/05/should-we-use-prestashop/#comments</comments>
		<pubDate>Tue, 18 May 2010 07:00:36 +0000</pubDate>
		<dc:creator>Eric Lamb</dc:creator>
				<category><![CDATA[Programming]]></category>
		<category><![CDATA[e-commerce]]></category>
		<category><![CDATA[open source]]></category>

		<guid isPermaLink="false">http://blog.ericlamb.net/?p=3135</guid>
		<description><![CDATA[I&#8217;m getting ready to put together an e-commerce site soon and, with the budget what it is (sigh), I have to use a third party package to build on instead of writing a custom platform. Not a new scenario, at a basic level, but it&#8217;s been a while since I&#8217;ve had to go with this [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m getting ready to put together an e-commerce site soon and, with the budget what it is (sigh), I have to use a third party package to build on instead of writing a custom platform. Not a new scenario, at a basic level, but it&#8217;s been a while since I&#8217;ve had to go with this strategy. Put plainly; I have no idea what my options are when it comes to e-commerce though I know I don&#8217;t want to go with <a title="Oscommerce" href="http://www.oscommerce.com/" onclick="return TrackClick('http%3A%2F%2Fwww.oscommerce.com%2F','Oscommerce')" target="_blank">OsCommerce</a> or <a title="CubeCart" href="http://www.cubecart.com/" onclick="return TrackClick('http%3A%2F%2Fwww.cubecart.com%2F','CubeCart')" target="_blank">CubeCart</a> or, and only because the client forbids it (seriously), <a title="Magento E-Commerce" href="http://www.magentocommerce.com/" onclick="return TrackClick('http%3A%2F%2Fwww.magentocommerce.com%2F','Magento+E-Commerce')" target="_blank">Magento</a>.</p>
<div id="attachment_3136" class="wp-caption aligncenter" style="width: 260px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/prestashop.jpg" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2Fprestashop.jpg','Should+We+Use+PrestaShop%3F')"><img class="size-full wp-image-3136 " title="Should We Use PrestaShop?" src="http://blog.ericlamb.net/wp-content/uploads/2010/05/prestashop.jpg" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2Fprestashop.jpg','Should+We+Use+PrestaShop%3F')" alt="Should We Use PrestaShop?" width="250" height="250" /></a><p class="wp-caption-text">Should We Use PrestaShop?</p></div>
<p><a title="PrestaShop" href="http://www.prestashop.com/" onclick="return TrackClick('http%3A%2F%2Fwww.prestashop.com%2F','PrestaShop')" target="_blank">PrestaShop</a> is an open source licensed (<a title="Open Source License 3.0" href="http://www.opensource.org/licenses/osl-3.0.php" onclick="return TrackClick('http%3A%2F%2Fwww.opensource.org%2Flicenses%2Fosl-3.0.php','Open+Source+License+3.0')" target="_blank">3.0</a>) e-commerce platform that I was recently introduced to by my friend Caroline; it&#8217;s not without it&#8217;s faults but there&#8217;s also a lot to like once you get past the boogers. PrestaShop has one of those open source business models that&#8217;s good for developers but kind of bad for the civilians. By that I mean if you know what you&#8217;re doing you can get a shop up and running with little to no cost outside of development time. If not, well you have to spend money in the <a title="PrestaStore" href="http://www.prestastore.com/" onclick="return TrackClick('http%3A%2F%2Fwww.prestastore.com%2F','PrestaStore')" target="_blank">PrestaStore</a> to buy modules for payment gateways and additional functionality.</p>
<p>Out of the box PrestaShop includes payment modules for Bank Wire, Cash on Delivery (COD), Google Checkout, Paypal, Paypal API and, seriously, checks (I imagine because nothing screams competent company like check by mail and COD payment options). If you want to use any other payment gateway, like Authorize.net for example, you either have to buy it from the PrestaStore for <a title="Authorize.net PrestaShop Module" href="http://www.prestastore.com/payment-modules-prestashop/443-payment-authorizenet.html" onclick="return TrackClick('http%3A%2F%2Fwww.prestastore.com%2Fpayment-modules-prestashop%2F443-payment-authorizenet.html','Authorize.net+PrestaShop+Module')" target="_blank">255 <em>fucking</em> dollars</a> or write your own. Seriously.</p>
<p>The documentation is lacking to say the least. There are all sorts of <a title="How to write PrestaShop modules" href="http://www.prestashop.com/wiki/FAQ_-_Frequently_Asked_Questions/#How_do_I_create_a_module_to_be_used_in_PrestaShop" onclick="return TrackClick('http%3A%2F%2Fwww.prestashop.com%2Fwiki%2FFAQ_-_Frequently_Asked_Questions%2F%23How_do_I_create_a_module_to_be_used_in_PrestaShop','How+to+write+PrestaShop+modules')" target="_blank">references</a> to a mythical &#8220;<a title="PrestaShop Developers Guide" href="http://www.prestashop.com/wiki/#Other_documentation" onclick="return TrackClick('http%3A%2F%2Fwww.prestashop.com%2Fwiki%2F%23Other_documentation','PrestaShop+Developers+Guide')" target="_blank">Developers Guide</a>&#8221; which is coming soon with no hint as to when it&#8217;s going to be made available. Since they have an entire site dedicated to <em>selling</em> modules it&#8217;s hard not to think of this as intentional (which makes PrestaShop look like dicks in my opinion).</p>
<p>One thing that&#8217;s pretty refreshing though is their honesty about incompatibilities with various versions of php. They even know what&#8217;s wrong with each version. Right there on the download page they have a very nice warning:</p>
<blockquote><p>* Some PHP 5 versions are bugged and prevent PrestaShop from working correctly:</p>
<p>* &#8211; PHP 5.2.1 (authentication is impossible)<br />
* &#8211; PHP 5.2.6 (authentication is impossible under 64bits servers)<br />
* &#8211; PHP 5.2.9 (image management/upload broken)<br />
* &#8211; PHP &lt; 5.2 (invalid date timezone)</p></blockquote>
<p>On the one hand it&#8217;s really cool that they know there are issues with  their software depending on the configuration. On the other hand though it&#8217;s a little unnerving that they know about the issues but haven&#8217;t fixed them yet. That says to me, and maybe it<em>&#8216;s</em> <em>just</em> me, that development is a little inconsistent and poorly managed; something you DON&#8217;T want when choosing any third party solution.</p>
<p>The PrestaShop installation process is actually pretty nice, though  the design is guaranteed to make your eyes bleed and it&#8217;s not without it&#8217;s bugs. The installer goes through the normal and standard system checks we&#8217;ve all became used to with third party packages which is nice. The only real issue is that the installer needs the last name field to be capitalized. Weird but really a non issue in the big picture.</p>
<div id="attachment_3161" class="wp-caption aligncenter" style="width: 310px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/PrestaShop_Installer_Caps1.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2FPrestaShop_Installer_Caps1.png','PrestaShop+Installer+Bug')"><img class="size-medium wp-image-3161" title="PrestaShop Installer Bug" src="http://blog.ericlamb.net/wp-content/uploads/2010/05/PrestaShop_Installer_Caps1-300x225.png" alt="PrestaShop Installer Bug" width="300" height="225" /></a><p class="wp-caption-text">PrestaShop Installer Bug</p></div>
<p>As to the larger issues of bugs and management, <a title="Nick Barlett" href="http://www.nickbartlett.com/wordpress/" onclick="return TrackClick('http%3A%2F%2Fwww.nickbartlett.com%2Fwordpress%2F','Nick+Barlett')" target="_blank">Nick Bartlett</a> has spent quite a bit of time documenting those. I haven&#8217;t had a chance to look into the extent of them yet, not having used PrestaShop in a production environment yet, but according to Nick&#8217;s blog, which I highly recommend checking out if you&#8217;re interested in PrestaShop, there are bugs and issues with <a title="PrestaShop Timezone Bug" href="http://www.nickbartlett.com/wordpress/prestashop-incorrect-order-time-solution/" onclick="return TrackClick('http%3A%2F%2Fwww.nickbartlett.com%2Fwordpress%2Fprestashop-incorrect-order-time-solution%2F','PrestaShop+Timezone+Bug')" target="_blank">timezones</a>, <a title="PrestaShop Remove Order" href="http://www.nickbartlett.com/wordpress/how-to-delete-an-order-with-prestashop/" onclick="return TrackClick('http%3A%2F%2Fwww.nickbartlett.com%2Fwordpress%2Fhow-to-delete-an-order-with-prestashop%2F','PrestaShop+Remove+Order')" target="_blank">removing orders</a>, <a title="Presta An Error Occured" href="http://www.nickbartlett.com/wordpress/prestashop-an-error-occurred-while-updating-object-cms/" onclick="return TrackClick('http%3A%2F%2Fwww.nickbartlett.com%2Fwordpress%2Fprestashop-an-error-occurred-while-updating-object-cms%2F','Presta+An+Error+Occured')" target="_blank">overzealous security hacks</a> and the <a title="PrestaShop Combinations Suck" href="http://www.nickbartlett.com/wordpress/prestashop-combinations-suck/" onclick="return TrackClick('http%3A%2F%2Fwww.nickbartlett.com%2Fwordpress%2Fprestashop-combinations-suck%2F','PrestaShop+Combinations+Suck')" target="_blank">product attributes</a> leaves much to be desired.</p>
<p>It should also be noted that I was never able to get the search engine friendly URLs to work. This was on Apache 2.2 CentOS 5 box. I don&#8217;t know why though I didn&#8217;t look into it too much. Could be my fault but I doubt it.</p>
<div id="attachment_3159" class="wp-caption aligncenter" style="width: 271px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/PrestaShop_Administration_Panel1.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2FPrestaShop_Administration_Panel1.png','PrestaShop+Administration+Panel')"><img class="size-medium wp-image-3159" title="PrestaShop Administration Panel" src="http://blog.ericlamb.net/wp-content/uploads/2010/05/PrestaShop_Administration_Panel1-261x300.png" alt="PrestaShop Administration Panel" width="261" height="300" /></a><p class="wp-caption-text">PrestaShop Administration Panel</p></div>
<p>The default theme is really gross for both the admin and client sites but it&#8217;s possible to create custom themes for the client site. You&#8217;ll have to suck it up for the admin site though.</p>
<div id="attachment_3160" class="wp-caption aligncenter" style="width: 306px"><a href="http://blog.ericlamb.net/wp-content/uploads/2010/05/PrestaShop_demo.png" onclick="return TrackClick('http%3A%2F%2Fblog.ericlamb.net%2Fwp-content%2Fuploads%2F2010%2F05%2FPrestaShop_demo.png','PrestaShop+Demo')"><img class="size-medium wp-image-3160" title="PrestaShop Demo" src="http://blog.ericlamb.net/wp-content/uploads/2010/05/PrestaShop_demo-296x300.png" alt="PrestaShop Demo" width="296" height="300" /></a><p class="wp-caption-text">PrestaShop Demo</p></div>
<p>Digging through the code leads to all sorts of insights. For example, the code style is a bit of a hybrid between procedural and OOP but in a very familiar way. It reminds me of a lot of projects; very logical. Interestingly, PrestaShop uses <a title="Smarty" href="http://smarty.net/" onclick="return TrackClick('http%3A%2F%2Fsmarty.net%2F','Smarty')" target="_blank">Smarty</a> as it&#8217;s templating mechanism. For me, this is really nice; especially since I&#8217;m already familiar with Smarty.</p>
<p>Also, as previously mentioned, there&#8217;s a module framework though, also as previously mentioned, the documentation doesn&#8217;t exist. So, in theory, it&#8217;s possible to extend on PrestaShop though I haven&#8217;t had a chance to dig into how that&#8217;s done exactly. Expect that to happen in the future though.</p>
<p>All and all, even with the bugs and &#8220;issues&#8221;, and keeping in mind that I haven&#8217;t actually <em>used</em> PrestaShop, I&#8217;m not against it. Yes, it sucks that the module everyone and their mother is going to need (Authorize.net) is a paid module but it&#8217;s still better than OsCommerce.</p>
<img src="http://feeds.feedburner.com/~r/MadeOfEverythingYoureNot/~4/HgJtlXayS7U" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://blog.ericlamb.net/2010/05/should-we-use-prestashop/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		<feedburner:origLink>http://blog.ericlamb.net/2010/05/should-we-use-prestashop/</feedburner:origLink></item>
	</channel>
</rss><!-- Dynamic page generated in 2.007 seconds. --><!-- Cached page generated by WP-Super-Cache on 2010-09-07 13:51:44 -->
