News Feed
Sections




News Archive
Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

php|architect Blog:
Less Code isn't Always Better
May 03, 2010 @ 13:16:59

On the php|architect blog Keith Casey has a new post that suggests something a bit counterintuitive to what a lot of developers think about their code - less code isn't always better.

Everyone says "I could build that in an afternoon/weekend/marathon session of caffeine-fueled code-debauchery" but to actually do something well, unsurprisingly, it usually takes longer.

He gives an example of this forum script that's under 1KB of code (949 bytes or so) and has some of the basic features of any forum software out there. Keith talks about the software - the features included, the included security, how it uses quotes to its advantage and how it only uses the basic functionality of PHP to make it all work.

Keith also includes a few criticisms of the code like how it uses short tags, the lack of linebreaks, using $_REQUEST and a few more.

To be blunt, it's not pretty and doesn't have many features, but honestly, I fluctuate between terrified and impressed by the feat. [...] More than anything, it's refreshing and fascinating to see what someone can do when they set clear, simple, direct priorities and focus exclusively on those.
0 comments voice your opinion now!
less code opinion forum example


blog comments powered by Disqus

Similar Posts

Cal Evans' Blog: Six ways to be a better client for your developer Point 1

Padraic Brady's Blog: Unit Testing: One Test, One Assertion - Why It Works

Wolfgang Drews' Blog: More on PHP Logos

PHPMaster.com: A First Look at React

DevShed: Creating an Administration Area for a Simple Threaded Discussion Forum


Community Events

Don't see your event here?
Let us know!


extension voicesoftheelephpant laravel opinion version release security series interview threedevsandamaybe community framework laravel5 api language podcast introduction unittest library symfony

All content copyright, 2015 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework