PHP Composer : Manage Package Dependency in PHP

What’s a PHP composer? How to use PHP composer in your PHP Application? What are the benefits of using composer in your application?

PHP Composer is a dependency manager. It manages the dependency of PHP packages in your application. Using composer you can pull the required library and dependencies and manage them in one place. The concept of a composer is similar to npm in node.js and gem in Ruby.

Let’s first understand what is a dependency.

PHP Traits Explanation with Example

PHP Traits

PHP Traits

PHP 5.4 introduces the concept of traits. In PHP 5.4 version several new features was introduced, one such feature was PHP traits.

PHP traits help us to minimize code duplication in our codebase. Until the concept of traits, PHP uses classical inheritance model in which one class can inherit only one class. But sometimes, it is beneficial to inherit from multiple classes to avoid code duplication. To solve this problem, PHP community introduces the concept of traits.

How to Install PHP 7 on Ubuntu

PHP 7 , the latest version of PHP was already released. It was released on December 3rd, 2015. PHP 7 comes with a number of new features, and the most amazing feature is  speed. PHP 7 provides an incredible performance boost to your web applications.

Here is the benchmark of PHP 7. PHP 7 benchmark.

In this tutorial, you’ll learn how to install PHP 7 on Ubuntu.

How to Install PHP, MySql, Apache in Ubuntu