Linux command: Change permission of files or folders

Here are some linux commands to change the permission of files and folders/directories. chmod is used change the file system mode / permission of files and folders. Change Particular File and Folder Permission This will give 775 permission to test directory which is insde /var/www directory chmod 775 /var/www/test This will give 664 permission to … Read more

Ubuntu: Installing Apache, PHP, MySQL & phpMyAdmin

Here are step-by-step commands about installing apache, php, mysql, and phpmyadmin on ubuntu. 1) Open Terminal – Press: CTRL + ALT + T 2) Install Apache – In terminal, type: sudo apt-get install apache2 – To test if Apache installation, Open browser and type: http://localhost – It should show text: It Works! 3) Install PHP … Read more

PHP: Read Write File, Read Scan Directory

Here is PHP code to: 1) Read / Scan any directory 2) Read any file 3) Write to any file 1) Read or Scan directory Get all files and folders inside the directory. Three ways are shown below. a) Read/Scan directory using opendir() and readdir() function $dir = "/var/www/test"; $dh = opendir($dir); while (false !== … Read more

How to Calculate Inverter & Battery Backup Time?

Here is a quick guide on calculating inverter and battery backup time. There are different capacity of inverters like 200VA, 250VA, 350VA, 400VA, 450VA, 500VA, 625VA, 1200VA, etc. The capacity of the inverter should be chosen based on how much watt of appliances you power at a time. How to convert from VA to Watts? … Read more

Magento: Show Billing-Shipping Address in Customer Signup-Registration page

Here are some ways (2 ways below) to show customer address information in registration page. When you fill up the address fields and signup then both your billing and shipping addresses are filled up. Here is how to enable address fields in signup page:- 1) First way [EASY] – Open template/customer/form/register.phtml – Just above this … Read more

Magento: SEO Tips on Meta Tags – Title, Keywords & Description

Here is a quick tip on how meta tags – title, keywords and description work on Magento. Meta information are not visible directly to end users but they are read by search engine spiders (bots). Meta tags are very important parameters for Search Engine Optimization (SEO). In Magento, you can keep meta tags for Category, … Read more