I am using nginx server for this documentation. First of all just choose a directory where you are gonna keep all your appliction files. Suppose, /var/www is going to be that directory.Create a directory and rename it with yourapplication-name. Inside that directory just create few pre-planned directory and file structure like the following. │ ├── routes ├── src ├── utilities ├── public ├── img ├── js ├── css ├── index.php ├── templates ├── composer.json We will manage and install all …
Tag: PHP
To enable xDebug in your nginx server you just first install xdebug by pecl command. sudo pecl install xdebug Now xdebug is installed in your system. Now find exactly where xdebug.so file was downloaded. You have to find it in /usr/lib/php5/(somewhere in this directory) Now after find the xdebug.so you have to open your PHP5-FPM’s php.ini file with sudo gedit /etc/php5/fpm/php.ini and add the following command (to locate the xdebug and enabling it). zend_extension=locationOfYourxDebugfile xdebug.remote_port=9000 xdebug.remote_enable=On xdebug.remote_connect_back=On xdebug.remote_log=/var/log/xdebug.log Now restart …
To use XAMPP’s PHP as default PHP in your command line to execute PHP commands fromyour command line/prompt you have to just follow the simple steps mentioned below: in this tutorial I used UBUNTU as my OS Open your terminal and open .bashrc file by following command: If you don’t use GUI or gedit not installed then you can use vim instead of gedit like following and just you have to add the following line at the end of your …
Today in my new PC I was just using a PHP application and I saw a error that says the following error: PHP Warning: strtotime(): It is not safe to rely on the system's timezone settings. You are required to use the date.timezone setting or the date_default_timezone_set() function Then I just figured out that I installed the latest version of PHP manually and in my php.ini file I didn’t tell PHP about my default timezone. Now I just open my …
Sometimes it is pretty important for programmers to auto deploy the latest Git repositories to update the local source codes in development server or live project server. After researching lots of easy and complex resource I found some pretty easy techniques to do that things in few minutes. Let’s see how we can accomplish this task which can save our big time. *in this article I used Ubuntu 12.04 Server OS and GitHub as code hosting platforms * Step 01 …