Sevalla is the all-in-one PaaS for your web projects. Host and deploy your applications, databases, object storage, and static sites. Enjoy advanced deployment pipelines, a complete database studio, instant preview apps, and one-click templates. The pricing is simple: no hidden fees, no seat-based pricing, and you pay only for what you use. Get real human support from developers.

Get started now with a $50 credit at Sevalla.com.

Why I support the league

Link –

Excellent post by Rafael Dohms on the The League Of Extraordinary packages.

“The League of Extraordinary Packages” is what I have dubbed a collective of composer packages. Its essentially a group of developers who have gathered under a single flag (or in this case a vendor name) and set standards for the packages that live there.

...

So these are a few reasons I like this effort:

  • Imposed Quality, Curated List ...
  • Reduced author fragility ...
  • Extended reach ...
  • Reduced duplication ...
http://blog.doh.ms/2015/03/10/why-i-support-the-league/

Read more

Stay up to date with all things Laravel, PHP, and JavaScript.

You can follow me on these platforms:

On all these platforms, regularly share programming tips, and what I myself have learned in ongoing projects.

Every month I send out a newsletter containing lots of interesting stuff for the modern PHP developer.

Expect quick tips & tricks, interesting tutorials, opinions and packages. Because I work with Laravel every day there is an emphasis on that framework.

Rest assured that I will only use your email address to send you the newsletter and will not use it for any other purposes.

Semantic versioning

Link –

Under this scheme, version numbers and the way they change convey meaning about the underlying code and what has been modified from one version to the next.

...

Given a version number MAJOR.MINOR.PATCH, increment the:

  1. MAJOR version when you make incompatible API changes,
  2. MINOR version when you add functionality in a backwards-compatible manner, and
  3. PATCH version when you make backwards-compatible bug fixes.
Additional labels for pre-release and build metadata are available as extensions to the MAJOR.MINOR.PATCH format.
http://semver.org/

Read more

How to install MCrypt on Yosemite to enable Laravel Artisan

Link –

The accepted solution thus far has been to install newer versions of PHP alongside Apple’s version using Homebrew or MacPorts. This would likely require you to compile the MCrypt extension manually. I also found that Homebrew could leave your system in disarray if things went wrong (more than once I had to do a complete restore because of this).

However, there’s another method I came across while research some non-related issues: install the latest version of PHP from a binary that includes the MCrypt extension. It will not bork up your system if you want to remove it, either.

https://medium.com/@genealabs/run-allthecommands-outside-of-homestead-e2fc8d05251f

Read more

Monitor all proposed changes to PHP

Link –

The next major release of PHP, version 7, is going to be an awesome release. Not only will performance be greatly improved, there probably will be lots of nice changes to the language.

The procedure on how PHP gets changed is easily readable and well documented. In short it comes down to this:

  • Proposed changes are submitted on the PHP Wiki.
  • There is a RFC (Request for comments) phase in which key members of the community and contributors can discuss the change.
  • After this round of discussion, which lasts a minimum of two weeks, they can vote if the proposed change gets implemented in a next version of the language.
If you want to closely monitor the future of PHP here's a tool to monitor all activity on the current RFC's.

Read more

Higher order functions in JavaScript

Link –

Functions that operate on other functions, either by taking them as arguments or by returning them, are called higher-order functions. If you have already accepted the fact that functions are regular values, there is nothing particularly remarkable about the fact that such functions exist. The term comes from mathematics, where the distinction between functions and other values is taken more seriously.
http://eloquentjavascript.net/05_higher_order.html

Read the article for some clear examples to help you understand the concept.

Read more

A package to backup your Laravel 5 app

Original – by Freek Van der Herten – 1 minute read

Last week I made a Laravel 5 package that could dump your db. Last saturday night I took the time to expand the functionality. laravel-backup can now backup your entire application. The backup is a zipfile that contains all files in the directories you specify along with a dump of your database. The…

Read more

PHP at the speed of C

Link –

Michael Maclean demonstrates how a 2100% performance gain can be achieved when rendering a Mandelbrot fractal using Recki-CT, a PHP compiler written in PHP.

Recently, Anthony Ferrara (known throughout the Internet and beyond as @ircmaxell) and Joe Watkins (similarly well-known as @krakjoe) have been working on a new set of toys for solving this problem while staying on the “standard” PHP runtime. Recki-CT is a set of tools that implement a PHP compiler, in PHP. While this might you think of things like PyPy, which implements a Python virtual machine in Python, this is not Recki’s goal – it doesn’t provide a VM, so it can’t run PHP by itself. However, it can parse PHP code and generate other code from it.
http://mgdm.net/weblog/php-at-the-speed-of-c/

Read more

Run tasks locally with Envoy

Link –

Envoy is an easy to use task runner created by master artisan Taylor Otwell. It offers a simple blade-like syntax to create tasks. If you're not familiar with it, you can watch this free Laracasts-video. Chris Fidao recently showed, in his excellent Servers For Hackers newsletter, how you can create a light version of Capistrano with Envoy.

Up until a few hours ago a task could only run via ssh. But now that this pull request has been merged, you can also use envoy to locally run commands.

Read more

Using StackPHP middleware in Laravel 5

Link –

Middleware is a series of wrappers around your application that decorate the request and the response. By wrapping the app in decorators you can add new behavious from the outside. This image explains the idea more visually:

[caption id="attachment_475" align="alignnone" width="726"]onion source: StackPHP.com[/caption]

 

The concept isn't new, solutions already exists for many languages (eg. Ruby, Python, Node, ...)

The PHP equivalent is StackPHP. Here's an excellent post by Richard Bagshaw explaining it. There are a lot of StackPHP style middlewares available that you can use in your applications.

Laravel 5 uses middleware for putting an application in maintenance mode, CSRF protection, authentication and more. Unfortunately Laravel 5 middleware isn't compatible with StackPHP-style middleware. Barry vd. Heuvel created at package to convert StackPHP middleware to Laravel 5 middleware and explained the inner workings on his blog.

Read more

Add a command to dump your database in Laravel 5

Original – by Freek Van der Herten – 1 minute read

This Laravel 5 package provides an artisan command to dump your database to a file. When installed you can dump your database with this command [code]php artisan db:backup``` A file containing the dump of your database will be created in the directory you specified in the config-file. I plan on…

Read more