Tuesday, May 31, 2016

How to enable extensions in PHP 7

Lets see how to enable cURL extension in PHP7


When yo update ubuntu on 16.04 or latest version then php upgrade to 6 to 7. 

Note: This guide is for those who have FULL access to the server, when system configuration can be changed. If you are using shared hosting, please contact your hosting provider.
Step 1: Check whether cURL extension is installed/enabled or not
To create a phpinfo file, open a plain text file, add the following lines, and save:
Filename: phpinfo.php
<?php
// Show all information, defaults to INFO_ALL
phpinfo();
?>
Visit the page in your browser. If you uploaded it to your html directory, you should now visithttp://www.example.com/phpinfo.php, replacing example.com with your own domain name.
At this point, search for the keyword “curl” and if it does not appear on the page, the extension might not be installed/enabled. Please proceed to the next step.
P.S: In this step, you are also able to locate where the “php.ini” configuration file is. Search for“Loaded Configuration File” and you might end up with something like:
Step 2: Ensure cURL extension for PHP is installed
On Windows, people often use WAMP (Windows, Apache, MySQL, PHP) bundles for local development. Fortunately, cURL extension is pre-installed with those bundles, so you can proceed to Step 3.
On Linux, it depends on which Linux distro the server is installed with, so you might need to run the appropriate command.
For example, with Ubuntu/Debian server, you need to run this command:
for php7:-
sudo apt-get install php7.0-curl
After that, restart the Apache server:
sudo service apache2 restart
for php5:-
sudo apt-get install php5-curl
After that, restart the Apache server:
sudo /etc/init.d/apache2 restart
After the Apache server has restarted, the extension should be enabled by default. You might use the method at Step 1 to check, and if not, please proceed to the next step.
Step 3: Enable cURL extension in “php.ini” file
Load the “php.ini” file located in Step 1 into your favorite text editor (if you are using Windows, we suggest Notepad++), then search for “php_curl”. At this point, you need to uncomment the line by removing the semicolon at the beginning of the line, as below.
After saving the file, restart the Apache server. Go to phpinfo page again to see if the extension is enabled.
If you see something like that, then congratulations, you have successfully enabled PHP cURL!

Monday, August 3, 2015

Git - how to merge branches

how to merge release-UAT branch:-

go to branch which is you want to merge. Eg:
git checkout release-UAT

Then run following command to merge feature-GS-2421 branch to release-UAT branch
git merge --no-ff feature-GS-2421

Then push release-UAT branch to remote repository.
git push origin release-UAT

Thursday, July 16, 2015

Emmet coding

http://docs.emmet.io/ http://docs.emmet.io/cheat-sheet/
.review-wrapper>h3.title+a.button+(ul>li*3>h3.name+.review-description+(ul>li*3))

Tuesday, July 14, 2015

Magento product types explained

Magento product types explained

Magento product types explained

Magento has various product types which all have slightly different functions. It's smart to take them all in consideration before choosing the Magento product type for your items. You probably think like: "Old news!", but before you move on… Do you know the difference between a Magento grouped product and a Magento bundle product?

Magento simple products

A Magento simple product is the most used product type for Magento webshops. This is because it's the most general product type of them all. A Magento simple product should be used for a single item without any specific selectable variations. Think about a coffee cup, a chandelier, a table or whatever.

Magento grouped products

A Magento grouped product should be used for a combination of Magento simple products. Think about a coffee cup that is sold together with a saucer, a silver spoon, a breakfast plate or whatever. You can't define a specific price for a Magento grouped product but you can define a discount amount.

Magento configurable products

A Magento configurable product should be used for a single item with specific selectable variations. Think about a coffee cup obtainable in different colours and sizes, a woman's bag obtainable in different materials, a light boll obtainable in different watts or whatever. Each selectable variation can have its own additional costs.

Magento virtual products

A Magento virtual product should be used for a virtual (not touchable) item. Think about an insurance, a reservation, an extra product guarantee or whatever. A virtual product does not allow selecting a shipping method at checkout simply because there's nothing to ship.

Magento bundle products

A Magento bundle product should be used for a bundle of simple (or virtual) products which are not to be sold separately. Think about a laptop where the customer can choose various items such as hard disk, processor, internal memory or whatever. Each of these items are simple (or virtual) products but can only be sold within the bundle product.

Magento downloadable products

A Magento downloadable product should be used for online software items. Think about an MP3 file, a PowerPoint presentation, a Magento extension or whatever. A downloadable product does not allow selecting a shipping method at checkout simply because there's nothing to ship.

Tuesday, July 7, 2015

Rename git branch locally and remotely

git branch -m old_branch new_branch         # Rename branch locally    
git push origin :old_branch                 # Delete the old branch    
git push --set-upstream origin new_branch   # Push the new branch, set local branch to track the new remote

Sunday, June 28, 2015

Wednesday, June 17, 2015

Re-index magento content using commandline

1) Go to the shell folder
cd shell
2) Re-index all
php indexer.php reindexall
3) View status
 $ php indexer.php --status

4)
$ php indexer.php info

5)
$ php indexer.php info