News Feed
Sections




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


PHP Town Hall:
Episode 30 Specs, Implementations, and New Engines OH MY!
August 26, 2014 @ 15:23:59

The PHP Town Hall podcast has posted their latest episode today with hosts Phil Sturgeon and Ben Edmunds with a few special guests: "Specs, Implementations, and New Engines OH MY!"

This week Ben and Phil are joined by core PHP developer extraordinaires Andrea Faulds and Levi Morrison. We discuss the new PHP engine spec, various RFCs, and all things internals. Also PHP 6 is officially dead, let's have a moment of silence.

You can check out this latest episode either through the in-page audio player, by downloading over on YouTube.

0 comments voice your opinion now!
phptownhall ep30 specs implementation engine podcast

Link: http://phptownhall.com/blog/2014/08/25/episode-30-specs-implementations-and-new-engines-oh-my/

Matthias Noback:
Decoupling your (event) system
August 26, 2014 @ 11:15:17

Matthias Noback has continued his look at event handling in PHP applications (well, Symfony-related ones at least) in his latest post. In this latest post he focuses more on abstracting out the event handling process and decoupling it from your application as much as possible.

You are creating a nice reusable package. Inside the package you want to use events to allow others to hook into your own code. You look at several event managers that are available. [...] Introducing this dependency is not without any problem: everybody who uses my/package in their project will also pull in the [event dispatcher] package, meaning they will now have yet another event dispatcher available in their project (a Laravel one, a Doctrine one, a Symfony one, etc.). This doesn't make sense, especially because event dispatchers all do (or can do) more or less the same thing.

As mentioned, he focuses in on the Symfony ecosystem and the event handlers commonly used there. He talks about some of the disadvantages of the Symfony EventDispatcher and how its interface can lead to code bloat due to it's verbosity (flexibility?). He talks about its violations of the Interface Segregation Principle and how he would structure the listener setup and handling if he was starting from scratch. To this end, he's created an adapter that wraps around an EventDispatcher interface and works with objects for the different kinds of events rather than the string names.

0 comments voice your opinion now!
decouple event manager dispatch handling symfony adapter object

Link: http://php-and-symfony.matthiasnoback.nl/2014/08/symfony2-decoupling-your-event-system/

SitePoint PHP Blog:
PINQ - Querify Your Datasets - Faceted Search
August 26, 2014 @ 10:58:22

The SitePoint PHP blog has continued their series showing the use of the PINQ library for PHP (a PHP implementation of the LINQ tool). In part one they introduced the tool and showed how to it could be used to query and sort data. In this second part they move on and show how to perform a multi-faceted search on data from a MySQL database.

We are not going to cover the full aspect of faceted search in this series. Interested parties can refer to relevant articles published on Sitepoint and other Internet publications. [...] Unfortunately, faceted search is not a built-in feature provided by MySQL yet. What can we do if we are using MySQL but also want to provide our users with such a feature? With PINQ, we'll see there is an equally powerful and straightforward approach to achieving this as when we are using other DB engines - at least in a way.

Building from the code from the first part of the series, they create a few more simple routes that let you define the different facets to use for the searching/sorting. He creates a custom facet class that uses the "traversable" handling of the PINQ to do the data manipulation. He creates a few different facet objects, each creating a customized filter. finally, he ties it all back into the endpoint and includes the updated markup to show the results. He finishes up the post mentioning a few limitations and improvements that could be made on the example as well.

0 comments voice your opinion now!
pinq query dataset mysql faceted search tutorial series part2

Link: http://www.sitepoint.com/pinq-querify-datasets-faceted-search/

Rob Allen:
Integrating ZF2 forms into Slim
August 26, 2014 @ 09:40:47

Rob Allen has a helpful post if you've ever wanted to take advantage of the simplicity of the Slim framework and the power of the Zend Framework 2 forms. In this latest post he walks you through the process of setting it all up and using the ZF2 elements outside of the main framework.

Let's say that you want to use Zend Framework 2′s Form component outside of ZF2 itself. In this case, a Slim application. It turns out that Composer makes this quite easy, though there's quite a lot of code involved, so this is a long article. Start with a really simple Slim Application...

His simple Slim application - just one route - handles both the GET and POST actions and uses several ZF2 components besides just the Form (dependencies mostly). He shows you the updates and additions you'll need to make to the service manager configuration and how to set up some custom validation and the form object in the controller. His example form only has two elements, an email field and a submit button and validation is done on the email address when it's submitted. Finally he includes the View object, extended from Slim's that combines some of the ZF2 and Slim handling to correctly render the form.

0 comments voice your opinion now!
form integration slim zendframework2 tutorial validation

Link: http://akrabat.com/zend-framework-2/integrating-zf2-forms-into-slim/

Community News:
Packagist Latest Releases for 08.26.2014
August 26, 2014 @ 08:00:14

Recent releases from the Packagist:

Community News:
Latest PECL Releases for 08.26.2014
August 26, 2014 @ 07:09:44

Latest PECL Releases:
  • SeasLog 1.1.4 - Define some function at header for C99 Standard - Remove some superfluous comment - Fixed SeasLog::log() function warning - Fixed config "seaslog.level = 0" in Readme

  • pecl_http 2.1.0RC3 Changes from RC2: * Fixed PHP-5.3 compatibility * Fixed possible bus error on shutdown when using events + Added curlcode transfer info - Removed port and scheme guessing of httpUrl for portability

0 comments voice your opinion now!



php[architect]:
August 2014 Issue Released - Beyond PHP
August 25, 2014 @ 12:46:00

The latest issue of the php[architect] magazine has officially been released - August 2014, Beyond PHP.

In an increasingly multi-hat career environment, most PHP Devs are often asked to knock out some front end development from time-to-time. This is not as unusual as you may think. Having learned coding in the home-baked-what-the-hell-are-we-doing-dot-com 1.0 world, we were often expected to do everything from cradle to grave. While duties are a lot more (and rightfully so) siloed between front and back end developers than in 1998, we are still expected to (at least) understand the different life-cycles of web development and design.

The articles in this month's issue include a wide range of topics including:

  • "MeteorJS - It's Not PHP But Darn It's Cool" (Alan Blount)
  • "Building a Plugin System with Composer" (Maarten Balliauw)
  • "A Modern Front End Through the Eyes of a PHP Developer" (Aurelio De Rosa)
  • "The Confident Coder: What Type Are You?" (Aaron Saray)

You can pick up a copy to call your own (either print or digital) directly from the php[architect] site. If you like the magazine, consider picking up a year subscription too!

0 comments voice your opinion now!
phparchitect magazine aug2014 issue release beyondphp

Link: http://www.phparch.com/magazine/2014-2/august/

SitePoint PHP Blog:
Build a New App with Laravel and EmberJS in Vagrant
August 25, 2014 @ 11:31:58

The SitePoint PHP blog has kicked off another series of posts today with part one of a series looking at building an application based on the Laravel PHP framework and EmberJS.

Nowadays, everything is turning into a web application. Even simple websites have a mobile app relying on a REST Api. Web applications are accessible everywhere - on a laptop, desktop, tablet, mobile, and recently on wearable devices like smartwatches. Everything is becoming smaller and faster - front ends are becoming separated from back ends, and only communicate with the server through APIs. In this series, we are going to create a photo uploading app. For the front-end, we will use EmberJs and Foundation 5. [...] For the back-end, we will use Laravel. The source code will be available per-part, and in final shape in the final part of this series.

They go with the Laravel Homestead virtual machine (and Vagrant) to make for a quick setup and stable environment. They help you get it all set up to push up to Heroku and get all needed dependencies, both frontend and backend, installed. They also walk you through the setup of the database, configuring the connection and deploying the application to production.

0 comments voice your opinion now!
tutorial emberjs vagrant laravel homestead application series part1

Link: http://www.sitepoint.com/build-new-app-laravel-emberjs-vagrant/

Matthias Noback:
Symfony2 Event subsystems
August 25, 2014 @ 10:07:09

In his latest post Mathias Noback takes a look at the Symfony2 event subsystems and the answer to a common problem he's had with it in the past: circular references.

Recently I realized that some of the problems I encountered in the past could have been easily solved by what I'm about to explain in this post. [...] The problem is: having a complicated graph of service definitions and their dependencies, which causes a ServiceCircularReferenceException, saying 'Circular reference detected for service "...", path: "... -> ... -> ...".' Somewhere in the path of services that form the circle you then find the event_dispatcher service.

He shows the wrong way to solve the problem first by injecting a service container into the listener and using services directly from there. In his "entirely different and much better way" he shows a solution that removes dependencies on the main event dispatcher. He shows how to use the event subsystems to avoid this link and gives a more concrete example for domain-related events (with both code and config).

0 comments voice your opinion now!
symfony2 event subsystem listener dispatcher domain

Link: http://php-and-symfony.matthiasnoback.nl/2014/08/symfony2-event-subsystems/


Community Events





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


wordpress application bugfix series community introduction configure library list language interview unittest developer podcast laravel release symfony install api code

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