News Feed
Sections




News Archive
feed this:

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

Pascal Martin:
PHP Version Statistics - October 2014
October 28, 2014 @ 11:23:13

Pascal Martin's latest post (in French, but the English version is coming soon) shares some statistics he's gathered around the usage of various software around the web, more specifically those involved in web-based applications.

I've collected statistics about the use of different PHP versions several times. The first time was in September 2011 and the most recent was in November 2013. At this point, PHP 5.2 still accounted for 34.4% of all PHP installations with PHP 5.3 moving up to 48.7%. This new data was collected the weekend of October 19th, 2014. At this point, the current stable versions of PHP are 5.4.34, 5.5.18 and 5.6.2. PHP 5.3 is no longer maintained (since August 14th 2014) and PHP 5.2 hasn't been supported for 4 years now.

He's broken up the statistics into a few different sections:

  • Web server software
  • Usage of major versions of PHP
  • Usage of minor versions of PHP
  • Versions in use under each of the major version numbers

He includes both the raw numbers (percentages) and some graphs showing the results in a bit more consumable fashion. It's interesting to see that, despite it being quite an old version now, PHP 5.3.x still has the largest share in the usage results.

UPDATE: He's posted the English version now as well.

0 comments voice your opinion now!
usage statistics oct2014 version major minor webserver

Link: http://blog.pascal-martin.fr/post/statistiques-versions-php-2014-10

Joshua Thijssen:
Internal PHP function usage revisited
August 06, 2014 @ 11:53:34

Joshua Thjissen has revisited some of his PHP internal function statistics, an update from this previous post with some results showing the most (and least) used internal PHP functions in several large projects from GitHub.

A lot of people are asking about functions like isset, empty, print, echo etc, as they are not present in the current result list. The thing is, is that these are not really functions, but language constructs. This means that PHP treats them a bit different than normal functions, and this results sometimes in seemingly "strange" behaviour when trying to use them like regular functions.

He's updated his results, though, to reflect the usage of these "functions" and shared the numbers. Not surprisingly, these constructs show up pretty highly in the new "top 22" list he's produced. With the inclusion of the constructs, the number one item on the list is now "isset" by a very large margin. The full results can be found in this gist.

0 comments voice your opinion now!
internal function usage statistics github revisit construct language

Link: https://www.adayinthelifeof.nl/2014/08/05/internal-php-function-usage-revisited/

Joshua Thijssen:
Internal PHP function usage
July 28, 2014 @ 10:05:39

Curious about the usage of the various "internal" (built-in, not user defined) functions in use is a wide range of PHP applications, Joshua Thijssen did some research on GitHub and has shared the results on his site today.

How many internal PHP functions (things like count(), strpos(), array_merge() etc), does PHP have? Depending on which version you use, and how many extensions you have loaded, somewhere between 1000 and 2000 would be a good guess. But how many of these internal functions are you REALLY using?

He created a custom script to fetch the results of a custom query (one that found repos with over fifty stars), grabbed the source and parsed the results looking for these internal functions. He shares the results of his parsing from 967 repos in the remainder of the post, including: the top ten most called, some interesting facts found in the results and some of the "bad" ones in wide use (like "exec" and "mysql_connect").

0 comments voice your opinion now!
internal function usage statistics github parse query

Link: https://www.adayinthelifeof.nl/2014/07/25/internal-php-function-usage/

SitePoint PHP Blog:
How to Speed Up Your App's API Consumption
April 11, 2014 @ 10:51:23

The SitePoint PHP blog has some advice posted today from Jacek Barecki about how you can speed up your use of other APIs with a few performance increasing tips.

In the process of creating a PHP application you may come to a point when keeping it isolated from remote resources or services may become a barrier in its development. To move along with the project you may employ different API services to fetch remote data, connect with user accounts on other websites or transform resources shared by your application. [...] But using APIs in an incorrect way can quickly lead to performance issues and lengthen the execution time of your script. If you're looking for a way to avoid it, consider implementing some of the solutions described in the article.

He recommends four things you can think about doing to help make the most effective use of these services:

  • Make multiple requests at a time
  • Separate API calls from the app main flow
  • Build a smart cache engine
  • Master the API documentation
0 comments voice your opinion now!
api performance recommendation tips usage

Link: http://www.sitepoint.com/speed-apps-api-consumption/

Erika Heidi:
Vagrant Usage Research
January 27, 2014 @ 10:15:07

If you've never heard of the powerful tool and you need automation around creating and configuring multiple virtual machines, you really should check it out. If you're curious as to how it's being used and what kind of things it's used for, check out this new post from Erika Heidi based on some research she recently did (and a survey she received some good feedback to).

From 11 to 14 of January, 720 Vagrant users from different sources (Twitter, IRC and the official Vagrant mailing list) answered a quick form I created to find out how people are using Vagrant. I'm currently in the process of writing a LeanPub book about this tool, and I was really curious especially about the provisioners usage.

She's put together the results in the form of an easy to read infographic with details about:

  • The most popular provisioners
  • The percentage of boxes running with OS
  • The percentage of languages on the boxes
  • The OS most Vagrant users use

...and finally the answer(s) to the question of "why vagrant?" but I'll leave it to you to read the post to find out that one.

0 comments voice your opinion now!
erika heidi vagrant usage research infographic survey

Link: http://www.erikaheidi.com/2014/01/24/vagrant-usage-research/

Kevin Schroeder:
(Basic) Configuring the Magento 2 Dependency Injection Container
December 16, 2013 @ 12:03:22

Kevin Schroeder continues his series of posts looking at using Magento 2 and creating customizations of the application. In this latest post he builds on the previous post about dependency injection and shows how to configure Magento's container.

The purpose of that post was to, perhaps, make you less apprehensive about using DI combined with the DIC in Magento 2. However, in this post I want to go a little deeper into the DIC, implemented via the MagentoObjectManagerObjectManager class, and talk about how to configure it. Configuration for the DIC is done in each module's etc/di.xml file or etc//di.xml. Because you can split DIC configuration based on the area this tells you that the /config/ naming stuff is over; which I applaud.

He focuses more specifically on two of the child nodes that can be defined - "type" and "preference" (you can also have "virtualType" as well). First up is "type" and he gives a simple example class in his "HelloWorld" example that just takes in a message and returns it when asked. He shows it in use and how to set up the "di.xml" configuration for the class, defining the "message" parameter in the configuration instead of in the object fetch (like the first example).

0 comments voice your opinion now!
magento2 dependency injection container configuration usage tutorial

Link: http://www.eschrade.com/page/basic-configuring-the-magento-2-dependency-injection-container/

Kevin Schroeder:
How much memory does Magento use?
December 10, 2013 @ 10:42:23

Kevin Schroeder was asked recently (as a part of a training class) about the amount of memory Magento actually uses during its execution. Magento is a widely-used e-commerce platform built in PHP.

Now, I know what you're supposed to set it at, but I've never measured actual usage. So I gave some bullcrap answer about how it really depends on a bunch of things and that I really shouldn't give a precise answer. But the individual persisted and I was forced to put my tail between my legs and admit that I didn't know. So I promised that I would take a look and here are my results.

He briefly mentions how he tested the memory usage of the code overall by adding an event to several spots in the application and using memory_get_usage. Using the sample Magento data he worked his way through the site and tracked the events/memory usage on the various page of the site including:

  • Main category page
  • Category page with images
  • Simple product page
  • Add to Cart

Each of these has a graph showing the memory usage at each stage. Additionally, he's graphed them all together to compare the overall memory consumption.He finishes off the post with a few summary items and conclusions from his results.

0 comments voice your opinion now!
magento memory usage consumption graph

Link: http://www.eschrade.com/page/how-much-memory-does-magento-use/

Reddit.com:
Why do you use frameworks?
November 08, 2013 @ 12:38:09

On Reddit.com there's a recent post that asks the community as a whole why they use frameworks in their applications...and if "everyone" uses them or not.

I've been programming php for about 1.5 years. I've heard lots about different frameworks and now I've been set a task by a potential employer to redesign some of my site using silex (http://silex.sensiolabs.org/). I've never used a framework before and I guess my question is why do you? Does EVERYONE use them or is it an "us vs them" kind of thing?

Comments to the post point out several different ideas around framework and their usage such as:

  • A framework doesn't have to be an MVC framework
  • There's nothing wrong with not using a framework
  • Frameworks as a toolbox
  • The increase in time-to-market speed they provide
  • Consistency when other developers work with the code
0 comments voice your opinion now!
framework community opinion usage

Link: http://www.reddit.com/r/PHP/comments/1q3gzg/why_do_you_use_frameworks/

Adam Culp:
PHP usage statistics
May 24, 2013 @ 11:41:16

Adam Culp has posted his own look at some of the PHP usage statistics that are out there and how they can be interpreted.

Every once in awhile I stumble across someone who is trying to find their way and decide what they will do in their career. As the organizer of a PHP user group I see many new developers passing through. Of course I always speak of how strong PHP is in the web markets, and encourage new web developers to pursue PHP as a tool in their box of goodies. Because as a web developer it would be a career limiting move to not have any knowledge of PHP. Here is why...

He shares a few different sources including w3tech's overall and PHP-specific information (PHP5 specific here) and the current results of the TIOBE index showing language popularity. For each he talks some about what the results mean (and don't mean) and how, if you're a "professional developer" you should, at the least, know PHP - the most dominant language in the web space.

0 comments voice your opinion now!
usage statistics language w3techs tiobe popularity

Link: http://www.geekyboy.com/archives/672

Thomas Buck:
Tom's PHP Commandments - Take heed
April 17, 2013 @ 12:23:20

Thomas Buck has put together what he calls "Tom's PHP Commandments" (nine of them) that developers should follow when developing applications with the language. Among his suggestions are things like:

  • ALWAYS do the simplest thing that will work
  • NEVER trust anything that comes from the user
  • NEVER use include for controlling logic
  • NEVER create a file of useful functions, even if it's called helpers.php

There's also been some discussion about this list over on Reddit - you can comment on it over there if you agree/disagree with some of his points.

0 comments voice your opinion now!
commandments language usage list

Link: http://biasedphp.com/php-commandments


Community Events





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


laravel podcast introduction language symfony version series mvc library voicesoftheelephpant interview tool release community security package composer framework opinion update

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