News Feed
Jobs Feed
Sections




News Archive
feed this:

Christopher Martinez:
Static code analysis tools for PHP
May 08, 2013 @ 12:38:22

Christopher Martinez has a recent post to his site that covers some of the static analysis tools available for PHP including the PHP Mess Detector, PHP CodeSniffer and the PHP Analyzer.

I believe in writing code that is easy to understand, easy to test, and easy to refactor. Yes, I realize that the statement above is pretty general and open to interpretation. Not everyone needs external tools to ensure quality in their code...but, I work on things from time to time that have absolutely no tests. [...] For whatever reason, this happens a lot more frequently in the PHP world. I'm guilty of not writing tests and checking how I write code, sometimes, too. Things are bright, though, for the PHP community - for quite some time now, we've had fantastic tools that assist us in writing better code.

He covers each of the tools, talks some about what they're good for and gives examples of their use, including output. He also talks some about the Pfff set of tools created by Facebook. He also talks some about how these tools fit into his daily work as a part of his pre-commit hooks in git.

0 comments voice your opinion now!
static code analysis tools description example

Link: http://chrsm.org/2013/05/05/code-analysis-tools-for-php

Project:
PHPHint.org - Online PHP Code Analysis
August 08, 2012 @ 10:18:59

Klaus Silveira has submitted a project he's come up with to help PHP developers detect problems in their code via a web-based application - PHPHint.org.

PHPHint is a community-driven, quick and easy to use, online tool that analyzes your PHP code and looks for potential errors, lack of best practices and code smell. It also allows you to clean your code automagically.

It was created to spread the work about the PSR standards and the PHP-FIG group, the importance of getting rid of code smell and applying to standards.

Since it is an open source project, you can help contribute if you'd like to see improvements to the service. It's great that it takes the relatively new PSR standards (PSR-1 & PSR-2) into account when analyzing the code too.

0 comments voice your opinion now!
phphintorg code analysis online psr1 psr2


Lorna Mitchell's Blog:
PHP Static Analysis Tool Usage
August 03, 2011 @ 10:50:22

In an informal poll Lorna Mitchell recently asked fellow developers to weigh in on what static analysis tool they used on their code. She's posted the results to her blog today with one of the tools being a clear winner.

My interest was mostly because I'm working on a book chapter which includes some static analysis content, and there are a couple of these tools that I include in my own builds, but I don't do much with the output of them. However I didn't want to drop anything from the chapter if it was actually a valuable tool and I was just missing the point - pretty much all the tools got a good number of votes though, so I'll be covering all of the [options].

According to her results, the most used tool by developers is the PHP_CodeSniffer with the PHP Mess Detector and PHP Copy & Paste Detector tied for second place.

0 comments voice your opinion now!
poll results static analysis tool codesniffer phpmd phpcopypaste


Gonzalo Ayuso's Blog:
Performance analysis fetching data with PDO and PHP.
March 28, 2011 @ 08:12:20

Gonzalo Ayuso has a new post to his blog today with the results of some performance analysis he ran when fetching data with PHP and PDO.

Fetching data from databases is a common operation in our work as developers. There are many drivers (normally I use PDO), but the usage of all of them are similar and switch from one to another is not difficult (they almost share the same interface). In this post I will focus on fetching data.

He includes his sample scripts - one using just fetch() and the other using fetchAll() - that include some timing and memory checking logic and includes the results of his "limit 10000" queries from his tables. Not surprisingly, the fetchAll required more memory than the fetch call. Event changing it to a loop of fetch() methods results in about the same amount of memory as a fetchAll.

0 comments voice your opinion now!
performance analysis benchmark pdo fetch fetchall memory


Gonzalo Ayuso's Blog:
Performance analysis using bind parameters with PDO and PHP
October 06, 2010 @ 08:57:02

Gonzalo Ayuso has posted the results of some performance testing he did with bind parameters in a PDO-based request for his application.

Some months ago a work mate asked me for the differences between using bind variables versus executing the SQL statement directly as a string throughout a PDO connection. Basically the work-flow of almost all database drivers is the same: Prepare statement, execute and fetch results. [...] What's the best one? Both method work properly. The difference is how databases manage the operation internally.

He gives two code examples, one with the bind parameters and one without, and the benchmark code he used to generate his statistics. It uses a PDO connection to execute several statements in a row both with bind parameters and without, measuring the time (with microtime) and outputting the results. His results show that while the simple update is faster, the bind parameter method has the added benefit of reusability for multiple queries.

0 comments voice your opinion now!
performance bind parameters pdo analysis benchmark


Etienne Kneuss' Blog:
Dataflow Type Analysis for PHP
January 14, 2010 @ 11:32:55

Etienne Kneuss has posted about a dataflow type analysis tools he's created that models code as control flow graphs.

It will assign types and let them flow through control structures. When reaching stability, it will check that the operations done of the values are sound type-wise. It will also do some structural checks.

There's some more technical details here and a presentation here but if you want to get at the code, you can grab it off of the project's github page.

0 comments voice your opinion now!
dataflow type analysis controlflow graph


Blue Parabola Blog:
Magento Feature Analysis Series
December 15, 2009 @ 09:56:56

In case you missed the whole series of posts that Matthew Turland did on the Magento e-Commerce platform, he's summed them all up in a new post to the Blue Parabola blog.

The new kid on the PHP e-commerce block, Magento, has gotten a good amount of attention leading up to and since its initial release. Earlier this year, I was entasked with doing an analysis of its features and thought it might make for an interesting series of blog posts. What you see here is the result. Comments are welcome, thanks in advance for your contribution.

Topics in the series covered the catalog browsing, customer service, shipping and SEO features the popular software has to offer.

0 comments voice your opinion now!
magento feature analysis series ecommerce


Blue Parabola Blog:
Magento Feature Analysis Series, Part 12 International Support Offering
September 25, 2009 @ 08:28:23

Matthew Turland is back with episode twelve of his "Magento Feature Analysis" series on the Blue Parabola blog. In this new article he focuses on the Internationalization support the popular e-commerce tool includes.

The list of features includes:

  • Multi-Lingual support
  • Tax Rate Support
  • Localization
  • Configurable List of Allowed Countries

You can find more in this series in this section of the BP blog and more about Magento from its website.

0 comments voice your opinion now!
magento feature analysis international


Blue Parabola Blog:
Magento Feature Analysis Series, Part 11 Search Engine Optimization Offering
September 18, 2009 @ 09:27:05

Matt Turland has posted his latest part of his in-depth look at Magento to the Blue Parabola blog - a look at the search engine optimization features (this is the eleventh part, you can catch up on other parts here).

This time he's focusing on the built-in search functionality with topics like:

  • 100% Search Engine Friendly
  • URL Rewrites give full control of URLs
  • Auto-generated Site Map for display on site
  • Auto-Generated Popular Search Terms Page

Other parts in this great series cover things like the checkout functionality, shipping features, order management and catalog/product browsing features. Check out them all for some more great content on this popular e-commerce platform.

0 comments voice your opinion now!
magento feature analysis


Blue Parabola Blog:
Magento Feature Analysis Series, Part 8 Payment Offering
September 10, 2009 @ 10:11:19

Matthew Turland has posted the eighth part of his detailed series looking at the feature set that the Magento e-commerce software has to offer to the Blue Parabola blog. This new post looks at the "payment offering" features.

Features mentioned in this post include:

  • Customer Store Credits Feature
  • Integrated with Amazon Payments
  • Gift Certificates/Cards (Physical and Virtual)
  • Integrated with Google Checkout
  • Accept Purchase Orders
  • Payment Extensions Available through Magento Connect

Check out the full post for more and descriptions of each.

0 comments voice your opinion now!
magento analysis feature payment offering



Community Events











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


rest symfony2 conference series opinion introduction example testing community usergroup release interview phpunit functional database zendframework2 language development podcast framework

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