News Feed
Jobs Feed
Sections



Recent Jobs

News Archive
feed this:

Nikita Popov's Blog:
Disproving the Single Quotes Performance Myth
January 10, 2012 @ 09:47:55

In this new post to his blog Nikita Popov aims to dispel the popular micro-optimization myth of using single quotes over double quotes for a performance boost.

If there is one PHP related thing that I really hate, then it is definitely the Single Quotes Performance Myth. [...] Let's do a random Google search for "PHP single quotes performance": You will get many results telling you that single quotes are faster than double quotes and that string interpolation is much slower than string concatenation. Most of them advise to use single quotes and concatenation to improve the performance of your application. Let's be clear here: This is pointless.

He did some benchmarking of his own to see how the myth would hold up and, as it turns out, it doesn't - "There is none". His proof compares two strings, one normal single-quoted and the other a double-quoted, and the opcodes they generate. They end up exactly the same. Since it's the opcodes that matter, he recommends using something like APC if you're really worried about the performance. He also includes an example using the token_get_all function of PHP to see how fast the strings run through the lexer too (again, almost no difference).

As an added bonus, he also throws in a bit about string concatenation versus string interpolation with some benchmarking scripts and results of their own.

0 comments voice your opinion now!
singlequote doublequote myth microoptimization benchmark string



Chris Hartjes' Blog:
CakePHP Mythbusters!
January 05, 2009 @ 08:47:16

In an effort to dispel some of the rumors and myths around the CakePHP framework (as presented most recently by a different blogger) Chris Hartjes has made a new "mythbuster" post to his blog today with a rebuttal to the points from the other article.

I ran across an article comparing CakePHP and Symfony and found that the writer had a number of preconceived ideas about CakePHP. These same ideas keep popping up everywhere, used by people looking to get their hate on about CakePHP. I sent a very well-reasoned email to the writer clearing up some of those misconceptions [...] So, in the interest of clarifying things about CakePHP I thought I would share that email, slightly rewritten for this blog posting, but the content is roughly the same.

The post/email covers a few different topics some might have misconceptions about concerning the framework:

  • Lack of Documentation
  • Scaffolding
  • Models are tied to controllers in a 1:1 relationship
  • Cake's Ajax and Javascript helpers do not support graceful degradation
  • Cake's HTML and Form helpers produces bad markup
  • Unit tests are an afterthought
  • CakePHP is not an "enterprise capable framework"
0 comments voice your opinion now!
cakephp framework mythbuster myth rumor unittest documentation scafffold


Jaybill McCarthy's Blog:
10 PHP Myths Dispelled
January 04, 2008 @ 14:17:00

As mentioned on the Zend Developer Zone, Jaybill McCarthy has written up a Blog post about ten of the PHP myths that are common on the web and the facts that dismiss them.

I am a PHP developer. Maybe even a halfway decent one. As such, I often find myself engaged in conversations on the subject of web application development in general and PHP in particular. I am continually flustered by the myths, half-truths and outright falsehoods that technical and non-technical people alike hold about this humble programming language.

Some of the points included in his "top ten" list are things like "PHP Encourages Sloppy Code", "PHP is slow because it's interpreted" and "PHP apps all look the same".

0 comments voice your opinion now!
myth dispell oop sloppy mvc interpreted ide debugger serious application myth dispell oop sloppy mvc interpreted ide debugger serious application


YoungCoders.com:
Debunking the Bloated Smarty Myth
October 11, 2006 @ 11:16:00

As mentioned in this new post on the Zend Developer Zone, there's a forum posting over on the YoungCoders.com website that looks to dispell the "age old" myth about Smarty - it's suposed bloated nature.

There has been a lot of talk about how Smarty, a popular template engine for PHP, is bloated and not useful because PHP is already a templating engine and that you're essentially creating a template engine out of a template engine. As everything I read could just say that it was bloated without backing up their statement, I decided to investigate it myself.

He describes what Smarty is and how to can help you and your site with compiled templates. There's a brief look at the syntax it uses and how it can help make the output of the site simpler than invoking PHP each time. He also gets a bit more indepth on the templating system, showing the process it uses to check the template and update if it needs to.

His conclusion? Smarty isn't that much different than any other kind of simple PHP-based templating language out there. So, what about the slowness? Well, he recommends checking your compiling setting - that's where the overhead is when the pages are loading.

0 comments voice your opinion now!
smarty myth dekunk bloated example template compile smarty myth dekunk bloated example template compile


Aaron Wormus' Blog:
What's Wrong with PEAR?
August 04, 2006 @ 05:47:06

In his latest blog post, Aaron Wormus asks the PHP community exactly "what's wrong with PEAR?"

I didn't attend Theo's talk, so the only information that I got was from the blog entries and slides. I realize that this short presentation was humorous, but it still brings up some points that have been nagging at the back of my head for a while now.

The comment in question is part of the Six Reasons PHP Sucks lightning talk.

The comment jokes about the quality of PEAR code. OF course, as Aaron notes, these types of comments aren't anythng new. The real issue at stake is that people don't understand PEAR. To help further the cause behind this (in)famous set of libraries, he's written an article for php|architect to dispell some of the myths.

I would like to dedicate this blog entry to people who think that PEAR does suck, and open up the discussion to what it is exactly that sucks. PEAR has issues, but I truly believe that most of the trash talking that is done is mainly due to the ignorance. So please, if you have issues, whether technical or package specific feel free to vent here.
1 comment voice your opinion now!
wrong pear library myth misunderstand lightning talk oscon2006 wrong pear library myth misunderstand lightning talk oscon2006



Community Events





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


unittest opinion framework introduction api community release series language component custom conference test podcast application database development phpunit symfony2 interview

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