The digest of interesting news and materials from the world of PHP for the last two weeks No. 18 (05/22/2013 - 06/03/2013)



    We bring to your attention the next selection with links to news and materials.

    Enjoy reading!


    News and Releases


    • Laravel 4 came out - Laravel 4 tutorials started appearing more than six months ago, which means that the framework was really waiting. Finally, you can see the result of more than a year of work. For those who are not familiar with the framework, but would like to take a look at it, the updated site has a quick start and a more detailed overview, see the screencast . By the way, let me remind you of the excellent and constantly updated database of screencasts for Laravel 4 - Laracasts . Well, for active users of the framework there is a wonderful resource laravel.io , which accumulates all the news and materials on Laravel.
    • Meet Stack - Igor Wiedler, who is already known as the author of React and the Silex microframework, this time described an agreement regulating how middleware components are combined into a layer between the web server and the PHP (Symfony) application. This idea was inspired by Rack , a solution from the Ruby world.
    • PHP 5.5.0RC2 Available - So, the second and, possibly, the latest release candidate for the new version of PHP. The next release is expected on June 6 and it is possible that this will be the final version.


    Php


    • PHP usage statistics - The author of this post reviews several statistical studies ( w3tech , TIOBE ) and tries to interpret the information received. In particular, the author believes that any professional developer should at least be familiar with PHP, as with the most popular web programming language.
    • Decorators in PHP , Extension Implementation - In this case, decorators are not understood as a design pattern, but python-style decorators. The author has implemented a PHP extension that adds the ability to use similar decorators in PHP. The second post describes implementation details of the extension itself. The post will be very useful for those who decide to take up writing their own extension.
    • The simplest example of generators in PHP - PHP 5.5 will be released very soon, in which a new feature is added - generators. In the post, a simple example and recommendations on the use of generators. More information on the generator can be found in the manual .
    • (int) ((0.1 + 0.7) * 10) - If you doubt the result of the indicated expression, then this post is for you. The author writes about the representation of real numbers in memory, and shows why, nevertheless, the result is 7.


    Learning Materials


    • Development in numbers - Excellent report from Anthony Ferrara. Very often, we hear people talking about how to write good code. But how can you objectively evaluate how good the code is and does it need refactoring? How to analyze an existing code without spending a week on subtraction? Tools such as pDepend and PHPLOC can give answers . But the results they produce may not be easy to understand and interpret.
      In his report, Anthony just examines the available tools for analyzing the quality of the code, gives theoretical information about the metrics used, demonstrates the application on real projects like Drupal. It also shows how to integrate metrics counting into the development process to improve the quality of the applications you create. Slides (PDF) .
    • Queues with RabbitMQ and PHP , 2 , 3 - A good tutorial in three parts on using the RabbitMQ platform. In the first part, general information and an overview of the possibilities, in the second and third ones directly on the creation and use of queues with examples in PHP.
    • Asynchronous MySQL queries in HipHop PHP - A small but useful post, which also deals with the implementation of the queue, but this time using the XBox message server built into HipHop.
    • Composing music using PHP - An entertaining post in which the author shows how you can generate a not entirely random sequence of notes. For this, it is proposed to use the Markov chain mechanism and training on a certain data set. That is, having sequences of notes from “good” compositions, it is possible to calculate the probabilities of one note following another and based on the data obtained to build new melodies.
    • Clash of the Titans: Zend vs. Symfony - A small overview of comparison frameworks. It would be interesting to make a full comparison of the titans ZF2 and Symfony 2.
    • How to create a group of PHP users - An interview with the leader of the PHP user group in Leeds, in which he shares his experience in creating a group, talks about the difficulties he has encountered and gives advice for those who are just going to create a user group.
    • Acceptance testing with Selenium and PHPUnit - An excellent tutorial on using Selenium, in which the author also shows how to export tests created on Selenium to PHPUnit tests. Screencasts are attached to every step.
    • Full coverage with tests is impractical - Writing tests is a rather “expensive” operation, therefore the author urges not to write tests for everything, but to test only really important cases and ignore the obvious points. Focus on creating a flawless product.
    • C for PHP - Due to the popularity of frameworks like Phalcon, the topic of writing extensions for PHP has really become interesting. The author of the post collected in one place links to resources and articles on this topic, for which he thanks.
    • PHP in the clouds - A small introductory tutorial on using cloud hosting AppFog , which by the way was previously called PHPFog.
    • 3 simple steps to improve the performance of a web application in PHP - In a post there are several recommendations for monitoring and improving the performance of PHP applications: accelerator, Composer-based autoloader, serialization of "heavy" objects.
    • Symfony2 on Windows Azure - The author of the post has implemented a bundle that allows you to transparently deploy Symfony2 applications to the Microsoft cloud platform.
    • Why in our business we chose Symfony2, and not another PHP framework - The author lists the features of Symfony 2 that made it necessary to choose this particular framework for solving problems. The author also draws attention to the fact that these opportunities are primarily important for business, and only then for developers.
    • Virtualize your stack with Vagrant and Puppet - A good screencast on how and why you should use Vagrant and Puppet to virtualize your work environment. At the end of the screencast, mention is also made of the excellent online configuration generator for Vagrant - PuPHPet , which over the past two weeks has acquired support for Nginx, PostgreSQL and xhprof.
    • Zend Framework 2 - HTML5 form elements - A simple tutorial that talks about HTML5 form elements: phone input field, email field, URL field and date / time selection element, support of which was recently implemented in ZF2
    • 10 steps to quickly track and fix bugs in PHP - An article with recommendations for finding and fixing bugs. And although some tips are beaten and very banal, but this is exactly the information that will not be superfluous to read again.
    • We create a template engine in PHP - A small tutorial on how to create your own simplest template engine.
    • 10 great PHP snippets - A selection of small, but very useful pieces of code for all occasions.
    • Optimal parallelization of unit tests or 17000 tests in 4 minutes - Excellent Habrapost with a detailed analysis of the task of organizing parallel execution of unit tests. The described solution uses TeamCity, however, the authors promise to soon open the project and provide support for other systems.
    • Organization of the backend and frontend in the Yii framework - An excellent article in which a detailed overview of possible options for implementing the separation of applications on the backend and frontend is made.
    • Working with AngularJS and Silex - A good tutorial on using Silex as a REST backend for AngularJS. A small screencast is also attached to the post.


    Materials from past conferences




    Link to the previous issue.

    Also popular now: