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

php[architect]:
December 2016 Issue Released - Scrutinizing Your Tests
Dec 02, 2016 @ 13:12:45

php[architect] magazine has officially announced the release of their last issue for 2016: the December 2016 edition - "Scrutinizing Your Tests":

The twelfth issue of 2016 is now available! This month we look at how to write good tests with Behat and using Test Driven Development. This issue also includes articles on using HTTPlug to decouple your HTTP Client, Decoupled Blocks with Drupal and JavaScript. Our columnists have articles on writing a Chat bot, advice on securing your application’s secrets, making better bug reports, respecting diversity, and a look back at 2016.

This issue includes articles like:

  • "Strangler Pattern, Part Three: the Rhythm of Test-Driven Development" (Edward Barnard)
  • "Decoupled Blocks with Drupal 8 and JavaScript Frameworks" (Matt Davis)
  • "Leveling Up: Building Better Bug Reports" (David Stockton)
  • "Community Corner: Focus on What We Have in Common" (Cal Evans)

And, as always, they provide a free article so you can get a feel for the content of the magazine. This month's talks about Behat by Konstantin Kudryashov. You can pick up a copy of your own directly from the php[architect] site.

tagged: phparchitect magazine december2016 scrutinize tests issue release

Link: https://www.phparch.com/magazine/2016-2/december/

TutsPlus.com:
Building Your Startup: Issue Tracking and Feature Planning
Dec 02, 2016 @ 12:56:23

TutsPlus.com has continued their "Building Your Startup with PHP" series today with this latest tutorial covering the creation of an issue tracking and feature planning process with the help of the Anana service.

Even for a one-person startup, it helps to have more than a spreadsheet (or paper) to track issues, ideas, and bugs. A few years ago, I'd used Lighthouse for my grant-funded NewsCloud Community Starter Project. Last year, I'd been introduced to Asana during a consulting gig.

[...] Eventually, I found my way and discovered the tool works well whether you're working with a variety of people or just solo. In today's episode, I'll walk you through how I began using Asana for Meeting Planner. I use Asana not only to track issues but to organize them and plan for the future. I also use it to track and process bugs.

He walks you through getting started with the service (they have a free tier) and how to set up your first project. He includes examples of task creation, tagging tasks and tracking bugs right inside the service. He then uses it to create a "release plan" for the next version of the Meeting Planner application. He wraps up the post talking about what's next on his side for the Planner application and its funding goals.

tagged: build startup series meetingplanner issue tracking feature planning tutorial

Link: https://code.tutsplus.com/tutorials/building-your-startup-issue-tracking-and-feature-planning--cms-26722

php[architect]:
November 2016 Issue Released - Moving Forward
Nov 02, 2016 @ 09:42:35

php[architect] magazine has officially released the latest issue, their November 2016 edition: "Moving Forward".

The eleventh issue of 2016 is now available! It’s time to download your copy of this issue of php[architect] magazine. This issue contains articles on the history of women in computing, using Abstract Classes/Interfaces/Traits, scaling with RabbitMQ, and custom extensions using Zephir. Our columnists have articles on Security scanners, advice for your first conference, improving your processes, understanding your editing tools, and more.

You can get more detail on the articles in this month's edition on the php[architect] website including:

  • "Dev Divas: History’s Heroines of Computing, Part Two" (Vesna Vuynovich Kovach)
  • "What Are Interfaces, Abstracts, and Traits?" (Chilion Snoek)
  • "Strangler Pattern, Part Two: Beginning to Design for Scale With RabbitMQ" (Edward Barnard)

And, as always, your favorite columns are back such as "Eduction Station" and "Security Corner". If you're interested in the content of the magazine, you can check out this free article for a sample. If you enjoy it, you can pick up a copy of your own (or subscribe) through the php[architect] site.

tagged: phparchitect magazine november2016 movingforward issue release

Link: https://www.phparch.com/magazine/2016-2/november/

Mark Baker:
PHP Generators – Sending “Gotchas”
Oct 11, 2016 @ 11:54:52

In this post to his site Mark Baker has shared some "sending gotchas" when generators are used in you PHP code. The focus of the article is on the "sending" part, pushing data into the generator for evaluation and use.

If you’re reading this, you’re probably already aware of just how useful PHP’s Generators are for improving performance and/or reducing memory overheads while keeping your code clean and easy to read.

Unlike their equivalent in some programming languages, PHP’s Generators allow you to send data into the Generator itself; not simply at initialisation (the arguments that we pass to the Generator when instantiating it); but also between iterations. This has its own uses, and again, allows us to move code from our main blocks and methods into the Generator itself. [...] However, there are a few “gotchas” when we combine Generators that both return and accept data in this way, and it really helps to be aware of them when we’re developing, otherwise it can create problems.

He starts simple, showing a generator that uses integers passed in as the starting number and addition interval for each loop. He gets a bit more complex in his next example, having a method called inside the loop. While the first instance of this behaves as expected, the second (after minor modification) yields unexpected results. He walks you through what's happening to produce those results and one possibility on how to get it corrected.

tagged: generator gotcha issue unexpected results debugging workaround

Link: https://markbakeruk.net/2016/10/08/php-generators-sending-gotchas/

php[architect]:
October 2016 Issue Released - Pillars of Development
Oct 04, 2016 @ 09:55:07

php[architect] magazine has just announced the release of the latest edition of their magazine, the October 2016 issue: Pillars of Development.

Articles in this issue include:

  • Juggle Arrays Using Functional Callbacks (Andrew Koebbe)
  • Dev Divas: History’s Heroines of Computing, Part One (Vesna Vuynovich Kovach)
  • The Strangler Pattern, Part One (Edward Barnard)
  • API Tips From the Front Line (Anna Filina)

The usual columns are also back including the "Education Station", "Security Corner" and "Leveling Up". If you'd like a sample of the contents of the issue, they're also offering a free article, "COTS, Open Source, Build it Yourself, or Something in Between?" by Eli White. If you pick up your own copy of this latest edition directly from the php[architect] website either as an individual issue or as a subscription (either digital only, print only or combined).

tagged: phparchitect magazine october2016 pillars development issue release

Link: https://www.phparch.com/magazine/2016-2/october/

Michelangelo van Dam:
PHP 7 on macOS Sierra
Sep 26, 2016 @ 09:24:18

Michelangelo van Dam has posted a "follow up" to his previous article about setting up a PHP installation on the recent versions of Mac OSX. In this new tutorial he makes some updates for the latest OS X release: Sierra.

Apple has released the latest version of their OS X operating system to the broad public and many have already upgraded their mac devices. But as it goes with each release, Apple likes to do things a bit different making it quite challenging for PHP developers to stay current with the latest PHP version (or other versions).

This version of mac OS (11.12) comes pre-installed with PHP 5.6.24. [...] Good for Apple, but this version reaches end-of-life support by the end of this year, so it would be great if you could upgrade to PHP 7.0 or even play with the latest PHP 7.1 release candidates.

While he points out that things like XAMPP and Homebrew can be used to set the installation up, he focuses more on compiling and installing it natively. He shares an issue he had with a missing runtime and how to get it installed and working happily so the PHP compile completes without issues.

tagged: mac osx runtime compile php7 sierra issue tutorial

Link: http://www.dragonbe.com/2016/09/php-7-on-macos-sierra.html

php[architect]:
September 2016 Issue Released - Legacy Code of the Ancients
Sep 02, 2016 @ 13:29:06

php[architect] magazine has officially announced the release of their September 2016 issue: Legacy Code of the Ancients.

We don’t always have the luxury of working on greenfield projects where we can try out the latest language features, component libraries, or programming techniques. More often, we’re asked to take care of and add features to an application that just works and supports a company or organization’s objectives—like making money to pay salaries. Unless it’s a relatively new project, you are sure to run into corners of the codebase that should be modernized. The trick is to find the time and marshal your team to do so.

Articles in this month's edition include:

  • "Illuminating Legacy Applications" (Colin DeCarlo)
  • "Legacy Code Needs Love Too" (John Congdon)
  • "Building for the Internet of Things in PHP" (Adam Englander)

The usual columns are there as well including the "Education Station" and "Security Corner". You can pick up your own copy of this month's issue directly from the php[architect] site. If you just want a sample of the content, check out this month's free article - "The Modernization of Multiple Legacy Websites".

tagged: phparchitect magazine september2016 legacycode legacy issue release

Link: https://www.phparch.com/magazine/2016-2/september/

php[architect]:
June 2016 Issue Released - Decoupled by Design
Jun 02, 2016 @ 14:58:51

php[architect] magazine has published their latest edition - the June 2016 issue, Decoupled by Design.

The June 2016 issue of php[architect] magazine is now available! Less tightly coupled code is easier to debug and re-use. This month we look at techniques to decouple different aspects of your code: including using asynchronous & distributed workers, transducers, middleware, and secure web services.

The issue includes articles like:

  • "Security Architecture: Securing your Web Services, Part Two" (Edward Barnard)
  • "The Middleware Awakens" (Ian Littman)
  • "MySQL’s JSON Data Type" (Dave Stokes)

...as well as several of the usual columns sharing community and professional development tips. If you're not a subscriber and want a sampling of the content, be sure to check out the free article for this month covering video manipulation with FFmpeg. You can also pick up a subscription directly from the php[architect] site if you want to read more.

tagged: phparchitect magazine june2016 decoupled design issue release

Link: https://www.phparch.com/magazine/2016-2/june/

php[architect]:
May 2016 Issue Released - Full Speed Ahead
May 03, 2016 @ 12:18:25

On the php[architect] site today they've announced the release of their May 2016 issue: "Full Speed Ahead".

We’ve just released the May 2016 issue of php[architect] magazine. To help you make good use of your development time, this month the magazine looks at libraries including DoctrineORM and FastRoute, and product development lessons from building Laravel Shift.

In addition, this month includes articles on defining “Senior Developer”, the value of gratitude, keeping credentials safe, securing web services, and the value of hindsight.

This month's issue also includes articles covering OAuth 2 and all of the usual columns (Education Station, Leveling Up, Community Corner, Security Corner). As always they provide one article free so you can get a taste of the latest issue. This time it's the article from Edward Barnard covering web services security. You can pick up a copy of your own directly from the php[architect] website or just get a year long digital or print subscription while you're there.

tagged: phparchitect magazine may2016 fullspeedahead issue release

Link: https://www.phparch.com/magazine/2016-2/may/

Leonid Mamchenkov:
Adventure in composer private repositories
Apr 22, 2016 @ 09:19:44

In this new post to his site Leonid Mamchenkov talks about some of his "adventure with Composer private repositories" in some of his deployment work with CakePHP 3 applications.

As good as the Packagist is, there is often a need for a repository or a package elsewhere. Whether it’s a commercial library, or sensitive corporate code, having an ability to store it outside of public eye and handle with the same ease and the same tool as the rest of the dependencies is a very welcome feature.

[...] We are setting up similar development and deployment process, but now for CakePHP-based projects. Things are much easier, since CakePHP 3 natively supports composer for the application itself and for its plugins. But we still have the need for private repositories here and there, so we follow the same setup as we did for WordPress.

Unfortunately he was getting a RuntimeException when he was trying to pull in a plugin through the same private repository workflow. Not only had he not seen the error before but the autoloader was configured as defined and other plugins were working with the same structure. As it turns out, it was the composer.json of the main application repository that was the problem. He includes the fix he made to the configuration on a sample CakePHP 3 project, showing how to switch it to a "vcs" type for more correct handling.

tagged: composer private repository issue runtime exception composerjson configuration

Link: http://mamchenkov.net/wordpress/2016/04/21/adventure-in-composer-private-repositories/