Categories
Development Tutorials

Getting Started with PHPUnit in Laravel

Note: I originally wrote and published this article as a Semaphore CI Community Tutorial. Introduction PHPUnit is one of the oldest and most well known unit testing packages for PHP. It is primarily designed for unit testing, which means testing your code in the smallest components possible, but it is also incredibly flexible and can […]

Categories
Development

Using Laravel 5 Middleware for Parameter Persistence

I am lucky enough to get to work on a large Laravel 5 full time in my day job, with some awesome developers.I recently came up with what is, in my humble opinion, an elegant and simple solution for what we all initiallythought was quite a complex problem. If you’ve used this trick before,or know […]

Categories
DigitalOcean Tutorials

How To Deploy Multiple PHP Applications using Ansible

Note: I originally wrote and published this article as part of the Automating Your PHP Application Deployment Process with Ansible tutorial series for the Digital Ocean Community. Introduction This tutorial is the third in a series about deploying PHP applications using Ansible on Ubuntu 14.04. The first tutorial covers the basic steps for deploying an […]

Categories
DigitalOcean Tutorials

How to Deploy an Advanced PHP Application Using Ansible

Note: I originally wrote and published this article as part of the Automating Your PHP Application Deployment Process with Ansible tutorial series for the Digital Ocean Community. Introduction This tutorial is the second in a series about deploying PHP applications using Ansible on Ubuntu 14.04. The first tutorial covers the basic steps for deploying an […]

Categories
DigitalOcean Tutorials

How to Deploy a Basic PHP Application using Ansible

Note: I originally wrote and published this article as part of the Automating Your PHP Application Deployment Process with Ansible tutorial series for the Digital Ocean Community. Introduction This tutorial covers the process of provisioning a basic PHP application using Ansible. The goal at the end of this tutorial is to have your new web […]

Categories
DigitalOcean Tutorials

How To Configure Apache Using Ansible on Ubuntu

Note: I originally wrote and published this article as a DigitalOcean Community Tutorial. Introduction Apache is one of the most popular web servers currently used on the Internet. It is easy to set up and configure on Linux distributions like Ubuntu and Debian, as it comes in the package repositories and includes a default configuration […]

Categories
Development

php artisan serve for Laravel 5

Important: In an entertaining example of poor timing, Taylor Otwell added the serve command back into the framework shortly after I published this. There is now no need to use this package. Users of Laravel 4 will remember that it came with a fantastic little command:

Categories
Development Testing

How to automatically create testing databases (in PHP & MySQL)

If you use an automated testing platform (such as Jenkins) you may have come across the problem where you need to manually create a new database (and sometimes user) every time you configure a different build or a different host. For small projects it’s not much of a chore, but for larger projects (or complicated […]

Categories
Development

Sorting an array with version number keys in PHP

There is a very quick and simple way to sort an array with version number keys in PHP.