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

SitePoint PHP Blog:
Building an Spress Svbtle Theme – Responsive Static Blogs!
Feb 11, 2016 @ 12:47:11

On the SitePoint blog there's a tutorial posted showing you how to create a responsive site template in Spress, a static site generator written in PHP.

You may have heard of Sculpin – a static site generator for PHP. [...] While easy to use and fast to set up, Sculpin’s development has stagnated a bit and the documentation leaves much to be desired. Spress is, in a way, its spiritual successor. Much better documentation, much more flexible configuration, much easier to extend, and just as easy to use with almost the same API and commands.

He starts by helping you set up a basic site to work with on a Homestead Improved instance. Once that's up and running (including an install of Spress) he creates the simple site and starts in on the rebuild of the Svbtle theme. He briefly explains how Spress themes work and then includes the code/layouts you'll need to reproduce the theme. The post includes a screenshot of what the end result should look like in two different browser sizes (responsive, remember).

tagged: spress static site generator responsive theme svbtle tutorial

Link: http://www.sitepoint.com/building-an-spress-svbtle-theme-responsive-static-blogs/

Laravel News Podcast:
LN 09: Laracon, Laravel Gurus, and more
Feb 11, 2016 @ 11:08:47

The Laravel News podcast has published their latest episode today - Episode #9: Laracon, Laravel Gurus, and More.

Episode 9 of the Laravel News podcast is now out and we discuss Laracon, Laravel Gurus, and more.

They talk about new speakers at Laracon this year, the relaunch of Laravel Gurus and a video from host Eric Barnes about why programming manuals aren't on audiobook. You can listen to this latest episode either by subscribing on iTunes or to their RSS feed and grabbing the links from there.

tagged: laravelnews laravel podcast news ep7 ericbarnes

Link: https://laravel-news.com/2016/02/ln-09-laracon-laravel-gurus-and-more/

Lorna Mitchell:
PHP 7.0 (and 5.6) on Ubuntu
Feb 11, 2016 @ 10:52:59

In this new post to her site Lorna Mitchell show you how to get both PHP 7 and PHP 5.6 installed on a Ubuntu-based system with the help of a custom PPA (Personal Package Archive).

PHP 7 is released but for those of us who don't usually compile our own PHP, it can be a long wait for our preferred distro to release the packages we want. For Ubuntu, I'm using a PPA which allows both PHP 5.6 and PHP 7.0 to be installed, including things like extensions, at the same time. It was very easy to set up (I'm running Ubuntu 15.10 but this process should also work on older versions back to at least 14.04 which is the previous LTS) so here's a quick walkthrough of what I did.

She then shows you how to:

  • Add the PPA to your system (this one)
  • Install the new versions as expected with apt-get
  • Configuring and switching between versions as needed

She ends the post talking about extensions and the issues that could come up when compiling them against each of the versions. This includes installation instructions so you can easily enable and disable the extensions much like the "sites available" some Apache installations use.

tagged: php7 php56 ubuntu ppa package install custom extension tutorial

Link: http://www.lornajane.net/posts/2016/php-7-0-and-5-6-on-ubuntu

Loïc Faugeron:
The Ultimate Developer Guide to Symfony - Event Dispatcher
Feb 11, 2016 @ 09:29:42

In a recent post to his site Loïc Faugeron has posted the second in his series of in-depth looks at a specific component of the Symfony framework. In this new article he provides the "ultimate developer guide" to the EventDispatcher component.

In this guide we explore the standalone libraries (also known as "Components") provided by Symfony to help us build applications. We've already seen [the] [HTTP Kernel and HTTP Foundation](https://gnugat.github.io/2016/02/03/ultimate-symfony-http-kernel.html). We're now about to check Event Dispatcher, then in the next articles we'll have a look at: routing and YAML, dependency injection and console [functionality].

He starts off with a basic introduction to the EventDispatcher component, describing the EventDispatcherInterface and how to implement the class with simple listeners and dispatch handling. He also shows how to extend this and create Event class implementations. Following this he circled back around to the HttpKernel component and describes how it makes heavy use of events in things like routing, controller requests, exceptions and views. For each he gives a bit of example code defining listeners that perform simple actions when executed.

tagged: ultimate developer guide symfony component eventdispatcher tutorial

Link: https://gnugat.github.io/2016/02/10/ultimate-symfony-event-dispatcher.html


Laravel News:
Laravel: Up and Running Available for Preorder
Feb 10, 2016 @ 11:34:08

If you're interested in the Laravel framework and possibly using it for your upcoming projects but aren't sure where to start, you should consider checking out Matt Stauffer's upcoming O'Reilly book "Laravel: Up and Running". According to this post on the Laravel News site the book is now available for pre-order.

Matt Stauffer has been writing a new book on Laravel named Laravel: Up and Running: A Framework for Building Modern PHP Apps and it’s published by O’Reilly Media. [...] This first edition is 250 pages and will come in either paperback or ebook form, but this current preorder is only available in paperback. Based on Amazon the expected shipping date is August 25, 2016.

The book walks you through the creation of a Laravel application from start to finish. it's no meant as a reference but a "work book" to teach the foundations of the framework. It hopes to provide a single point where developers, especially those familiar with "C-family programming languages", will be able to get started quickly.

tagged: laravel upandrunning oreilly preorder book mattstauffer framework introduction

Link: https://laravel-news.com/2016/02/laravel-up-and-running-available-for-preorder/

Alejandro Celaya:
How to properly implement persistent login
Feb 10, 2016 @ 10:55:37

In his latest post to his site Alejandro Celaya shares some suggestions about how to make a good, safe persistent login feature for your application. This is usually referred to as the "remember me" handling and is widely used to help improve the overall user experience.

I'm sure you are familiar with those "remember me" checkboxes in login forms. They are a common way to allow a user to keep his/her session in a web application for an extended period of time when he is in a trusted computer.

One could think that it is a small and easy-to-implement feature, but it has indeed a lot of considerations. [...] In this article I’m not going to show you how to implement a persistent login in one or another programming language, but what are the good practices that should be followed when you implement it in the way you want.

He starts off with some thoughts about the wrong way to handle the persistent login (like just making a long-life cookie) and what some of the consequences could be. Instead he suggests using a cookie (with a random generated token) that's long running, maybe 2 weeks. The difference here is that this token is then refreshed once the token is validated and reset. This reduces the risk of an older token being used on another source too. He also shares some other security concerns to think about in this setup including the use of one-time tokens, potential multiple persistent sessions and when it might be good to re-prompt for the password.

tagged: persistent login security rememberme implementation advice options

Link: http://blog.alejandrocelaya.com/2016/02/09/how-to-properly-implement-persistent-login/

Marc Morera:
You Probably Need Bundle Dependencies
Feb 10, 2016 @ 09:04:18

In this post to his site Marc Morera responds to some comments from another post about bundles dependencies in Symfony-based applications.

This post tries to answer the Magnus Nordlander’s blog post, and to explain why the Symfony Bundle Dependencies is not just a personal project to fulfill my bundles dependencies, but a practice we should implement in all our Symfony bundles as well.

Believe me, I had a big post to explain why people really need this bundle, but I think that you don’t need these words, but a simple and real example.

He points out a more "real world" example of why this kind of dependency system can be useful in Symfony development. He points out a common service (security.encoder_factory) that's used widely across many bundles, but also defined as a dependency in each. If the bundle dependency structure/tool was in wide use, this dependency would be define elsewhere and not as a part of the bundle itself.

tagged: bundle dependencies symfony security factory example

Link: http://mmoreram.com/blog/2016/02/09/you-probably-need-bundle-dependencies/

Community News:
Recent posts from PHP Quickfix (02.10.2016)
Feb 10, 2016 @ 08:05:01

Recent posts from the PHP Quickfix site:

tagged:

Link:

Ibuildings Blog:
Submit to the Dutch PHP Conference (DPC) Call for Papers!
Feb 09, 2016 @ 11:52:45

As is mentioned in this new post to the Ibuildings blog, the Call for Papers for the Dutch PHP Conference is currently open and accepting submissions until February 22nd.

This year Ibuildings will host the Dutch PHP Conference (DPC) in Amsterdam for the tenth time in a row, on June 23rd - 25th. As you may have noticed, since a couple of weeks you can send in your tutorial or talk proposals. The Call for Papers closes on February 22nd.

DPC offers a stage to veteran speakers as well as the less experienced and debuting speakers. [...] We're looking for speakers who talk about subjects that they're passionate about. Talks don't necessarily need to be about PHP development: any subject that might be of interest to PHP developers is welcome.

The post also includes some suggestions that could help you get accepted as a speaker for the conference including:

  • sending more than one proposal
  • getting reviews of the proposals either from coworkers or something like helpmeabstract.com
  • practice giving presentations locally too

Be sure and get those proposals in the February 22nd deadline before

tagged: callforpapers cfp dutchphpconference dpc16 submit community conference amsterdam

Link: https://www.ibuildings.nl/blog/2016/02/submit-dpc-call-papers