Useful everyday Git commands

Checkout remote branch

Git pull force

Get files from another branch

Delete remote branch

Read More

Installing remote xdebug with phpstorm

There are some reasons why you need to debug remotely. If your project has complex infrustructure. It will be difficult or time consuming to install all necessary environment. This tutorial shows how to install remote xdebug with phpStorm. Setting up remote xdedug parameters Add the following settings to xdebug.ini

Restart php

 …

Read More

Difference between abstract class and interface in PHP

Abstract class Abstract class is not directly instantiable, but acts as a common base for children classes. In abstract class you should mark a class as abstract by placing the abstract keyword before class and must have at least one abstract method.

Interface Any class that has the Interface must implement all methods listed…

Read More

Linux commands for WEB developers

Copy a folder

What port is used?

Find and delete files greater than a given size

Find a file

Read More

MySQL Question 1

Question There are two tables: How to get count of unique values from table t1? Answer

Read More

How to change php version in shell

If you have multiple versions of PHP and you want to change PHP version in shell then run following command:

This will give you a list of all PHP versions installed:

Find version that you need (i.e. /usr/bin/php71). Then open .bashrc (or .bash_profile) and add the following line to the end of the…

Read More

Installing Nginx + PHP-FPM + MySQL on OS X

Setting up working environment is the first step you need to do. This will be your local web server for programming in OS X with PHP, Nginx and MySQL (also known as LEMP). Let’s make it as ease as possible 😉   What we will do Install xcode (for license) and brew package manager (as…

Read More

How to install free SSL certificate on Nginx with StartSSL

First, we need issue SSL certificate. Startssl.com is a great way to install free signed SSL certifacate. So, let’s signed up on Startssl.com with browser authenticate. Then, go to control panel (https://startssl.com/ControlPanel) and click on Validations Wizard tab. Select Domain Validation option. Next, enter your domain name: You will be asked to verify your domain…

Read More

Hello world!

Welcome to WordPress. This is your first post. Edit or delete it, then start writing!

 …

Read More