Installing PHP Extensions on Nitrous.io
Inspired by a comment on his previous article 'Getting Started with Laravel on Nitrous.io', Bruno Skvorc realised that Nitrous was still a bit too complicated to customise properly. In this tutorial, he glides through installing cURL and Phalcon on a Nitrous.io PHP box.
Using An Azure Database from PHP on Linux
The cloud is the newest buzzword in all things development, and there are many different options for utilising the nebulous cloud. Amazon Web Services, Microsoft Azure and Digital Ocean (just to name a few) are some providers that give you various levels of cloud computing. While all three give you Virtual Private Hosting, Microsoft has stepped up their offering.
Auto Injecting Dependencies in PHP Objects
It took Gonzalo Ayuso a while to come up with a decent title for this post. While it's not the most descriptive of titles, he wanted to use the simple idea of automating the Hollywood Principle (“Don’t call us, we’ll call you”).
Using MySQL Fabric From Any Programming Language
MySQL Fabric is a framework for MySQL Replication high availability, automatic failover and sharding. Technically, a MySQL Fabric daemon monitors a set of MySQL servers and takes appropriate actions upon failure. Clients use Fabric aware drivers to learn about failed servers and shards to distribute queries accordingly. Simple to understand, simple to sell, simple to raise false expectations and simple to fail [, dear Sales]. With the usual blog posts telling only the story of the first three sentences, major parts of the story are covered in silence.
Functional Testing in Symfony2
In his previous article, Taylor Ren demonstrated how to load sample data into a Symfony development environment. The test data may not be useful as it stands on its own. When coupled with Functional Testing, however, it becomes a life saver.
How to Use a Webcam To Take Pictures in PHP Application
Basic PHP Form Validation
A quick tutorial showing how easy it is to validate form data with php. This can help cut down on spammers, and it can help to ensure that email addresses are at least formatted correctly.
Symfony2 Components Overview: Validator
In the first five posts of this series we have been talking about key components for any PHP framework from the point of view of their internals, such as HttpFoundation to abstract the HTTP protocol, HttpKernel to convert a Request into a Response, Routing to map requests to controllers, EventDispatcher to add reusability and extensibility, and Config to load and validate configuration values. This time we’ll delve deeper in the user space to describe a component that is for specific apps rather than just for frameworks. Today’s topic will be the Validator component.
HHVM: Tracking Parity
HHVM has a large suite of unit tests that must pass in several build configurations before a commit reaches master. Unfortunately, this test suite passing doesn’t tell you if HHVM can be used for anything useful – so we periodically run the test suites for popular, open source frameworks.
Persisting Value Objects in Doctrine
Ross Tuck has been using more and more Value Objects in his applications over the last year, primarily with Doctrine ORM. Value Objects are an extremely powerful technique and he has been impressed with how much they can clean up a codebase. One of the main questions he had when starting with Value Objects is how to persist them with Doctrine. This post attempts to create a reference for all the different persistence techniques he has seen so far.
Lessons Learned Implementing AES in PHP using Mcrypt
The Advanced Encryption Standard (AES) is the successor of triple DES. When you need a standardised, secure, high performance symmetric cipher it seems like a good choice. Wi-Fi network traffic is encrypted with AES for instance. Also when you want to securely store data in a database or on disk you could choose AES. Many SSDs store data internally using AES encryption. PHP supports AES through “mcrypt”. On Debian based systems (like Ubuntu and Mint) you can install it using “sudo apt-get install php5-mcrypt”.