29 January 2010

Are you wondering how to delete all test orders you have made in Magento while testing? In Sandbox mode store owners performs many transactions to make sure that their Magento powered store is capable of handling payment transactions. You can use any Payment Gateways like PayPal, Authorize.net, PayFlow or Amazon Simple Pay. But all the test orders remain in system even when your store goes into production.
Unfortunately, there is no way in Magento to delete those test orders which were made while testing the Magento store. You can only process these order and set their status as “Cancelled” but you can’t really delete those test orders from your store. I am sure that you would love to see a “Delete selected Orders” button in Magento Admin panel; unfortunately you won’t find such functionality. In order to delete these test orders you have to log in to your PhpmyAdmin using full access and run few queries to get rid of those test orders.
How To Delete A Single Test Order Using PhpMyAdmin
You need to run the following query on your database using PhpMyAdmin:
1 2 3 4 | set @increment_id='200000111'; select @order_id:=entity_id from prefix_sales_order_entity where increment_id=@increment_id; delete from prefix_sales_order_entity where entity_id=@order_id or parent_id=@order_id; delete from prefix_sales_order where increment_id=@increment_id; |
In the above example we are trying to delete test order # ‘200000111′. Generally people use prefix so change the “prefix_” in the above query with the prefix you have chosen for your Magento store.
The above query will delete the single test order or even an actual order from your Magento store. All you have to do is provide an order number and database prefix. Rest will be taken care of automatically.
How To Delete All Magento Test Orders In One Go
This step is done only on new store which are ready forproduction and don’t have any “Actual Orders” in the system. I would highly recommend taking a full backup before you proceed. Basically when you run the following queries on your Magento database it will complete wipe out all the records and reset the order counters. If you are about to indulge, then please make sure that you know what you are doing.
Beware: The following steps can’t be reversed.
Go to your PhpMyAdmin and run SQL Query
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 | SET FOREIGN_KEY_CHECKS=0; TRUNCATE `sales_order`; TRUNCATE `sales_order_datetime`; TRUNCATE `sales_order_decimal`; TRUNCATE `sales_order_entity`; TRUNCATE `sales_order_entity_datetime`; TRUNCATE `sales_order_entity_decimal`; TRUNCATE `sales_order_entity_int`; TRUNCATE `sales_order_entity_text`; TRUNCATE `sales_order_entity_varchar`; TRUNCATE `sales_order_int`; TRUNCATE `sales_order_text`; TRUNCATE `sales_order_varchar`; TRUNCATE `sales_flat_quote`; TRUNCATE `sales_flat_quote_address`; TRUNCATE `sales_flat_quote_address_item`; TRUNCATE `sales_flat_quote_item`; TRUNCATE `sales_flat_quote_item_option`; TRUNCATE `sales_flat_order_item`; TRUNCATE `sendfriend_log`; TRUNCATE `tag`; TRUNCATE `tag_relation`; TRUNCATE `tag_summary`; TRUNCATE `wishlist`; TRUNCATE `log_quote`; TRUNCATE `report_event`; ALTER TABLE `sales_order` AUTO_INCREMENT=1; ALTER TABLE `sales_order_datetime` AUTO_INCREMENT=1; ALTER TABLE `sales_order_decimal` AUTO_INCREMENT=1; ALTER TABLE `sales_order_entity` AUTO_INCREMENT=1; ALTER TABLE `sales_order_entity_datetime` AUTO_INCREMENT=1; ALTER TABLE `sales_order_entity_decimal` AUTO_INCREMENT=1; ALTER TABLE `sales_order_entity_int` AUTO_INCREMENT=1; ALTER TABLE `sales_order_entity_text` AUTO_INCREMENT=1; ALTER TABLE `sales_order_entity_varchar` AUTO_INCREMENT=1; ALTER TABLE `sales_order_int` AUTO_INCREMENT=1; ALTER TABLE `sales_order_text` AUTO_INCREMENT=1; ALTER TABLE `sales_order_varchar` AUTO_INCREMENT=1; ALTER TABLE `sales_flat_quote` AUTO_INCREMENT=1; ALTER TABLE `sales_flat_quote_address` AUTO_INCREMENT=1; ALTER TABLE `sales_flat_quote_address_item` AUTO_INCREMENT=1; ALTER TABLE `sales_flat_quote_item` AUTO_INCREMENT=1; ALTER TABLE `sales_flat_quote_item_option` AUTO_INCREMENT=1; ALTER TABLE `sales_flat_order_item` AUTO_INCREMENT=1; ALTER TABLE `sendfriend_log` AUTO_INCREMENT=1; ALTER TABLE `tag` AUTO_INCREMENT=1; ALTER TABLE `tag_relation` AUTO_INCREMENT=1; ALTER TABLE `tag_summary` AUTO_INCREMENT=1; ALTER TABLE `wishlist` AUTO_INCREMENT=1; ALTER TABLE `log_quote` AUTO_INCREMENT=1; ALTER TABLE `report_event` AUTO_INCREMENT=1; -- lets reset customers TRUNCATE `customer_address_entity`; TRUNCATE `customer_address_entity_datetime`; TRUNCATE `customer_address_entity_decimal`; TRUNCATE `customer_address_entity_int`; TRUNCATE `customer_address_entity_text`; TRUNCATE `customer_address_entity_varchar`; TRUNCATE `customer_entity`; TRUNCATE `customer_entity_datetime`; TRUNCATE `customer_entity_decimal`; TRUNCATE `customer_entity_int`; TRUNCATE `customer_entity_text`; TRUNCATE `customer_entity_varchar`; TRUNCATE `log_customer`; TRUNCATE `log_visitor`; TRUNCATE `log_visitor_info`; ALTER TABLE `customer_address_entity` AUTO_INCREMENT=1; ALTER TABLE `customer_address_entity_datetime` AUTO_INCREMENT=1; ALTER TABLE `customer_address_entity_decimal` AUTO_INCREMENT=1; ALTER TABLE `customer_address_entity_int` AUTO_INCREMENT=1; ALTER TABLE `customer_address_entity_text` AUTO_INCREMENT=1; ALTER TABLE `customer_address_entity_varchar` AUTO_INCREMENT=1; ALTER TABLE `customer_entity` AUTO_INCREMENT=1; ALTER TABLE `customer_entity_datetime` AUTO_INCREMENT=1; ALTER TABLE `customer_entity_decimal` AUTO_INCREMENT=1; ALTER TABLE `customer_entity_int` AUTO_INCREMENT=1; ALTER TABLE `customer_entity_text` AUTO_INCREMENT=1; ALTER TABLE `customer_entity_varchar` AUTO_INCREMENT=1; ALTER TABLE `log_customer` AUTO_INCREMENT=1; ALTER TABLE `log_visitor` AUTO_INCREMENT=1; ALTER TABLE `log_visitor_info` AUTO_INCREMENT=1; -- Now, lets Reset all ID counters TRUNCATE `eav_entity_store`; ALTER TABLE `eav_entity_store` AUTO_INCREMENT=1; SET FOREIGN_KEY_CHECKS=1; |
Optional: If you are looking to set appropriate prefixes for orders, invoices, shipments, credit memos then run the following query as well:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | INSERT INTO `YOUR_DB_NAME`.`eav_entity_store` (`entity_store_id` ,`entity_type_id` ,`store_id` ,`increment_prefix` ,`increment_last_id`) VALUES ('1', '11', '1', '1', '000000000'); update `eav_entity_store` set `increment_prefix`= 1 where `entity_type_id`='4' and `store_id`='1'; update `eav_entity_store` set `increment_last_id`= '000000000' where `entity_type_id`='4' and `store_id`='1'; INSERT INTO `YOUR_DB_NAME`.`eav_entity_store` (`entity_store_id` ,`entity_type_id` ,`store_id` ,`increment_prefix` ,`increment_last_id`) VALUES ('2', '16', '1', '2', '000000000'); update `eav_entity_store` set `increment_prefix`= 2 where `entity_type_id`='18' and `store_id`='1'; update `eav_entity_store` set `increment_last_id`= '000000000' where `entity_type_id`='18' and `store_id`='1'; INSERT INTO `YOUR_DB_NAME`.`eav_entity_store` (`entity_store_id` ,`entity_type_id` ,`store_id` ,`increment_prefix` ,`increment_last_id`) VALUES ('3', '19', '1', '3', '000000000'); update `eav_entity_store` set `increment_prefix`= 3 where `entity_type_id`='24' and `store_id`='1'; update `eav_entity_store` set `increment_last_id`= '000000000' where `entity_type_id`='24' and `store_id`='1'; INSERT INTO `YOUR_DB_NAME`.`eav_entity_store` (`entity_store_id` ,`entity_type_id` ,`store_id` ,`increment_prefix` ,`increment_last_id`) VALUES ('4', '23', '1', '4', '000000000'); update `eav_entity_store` set `increment_prefix`= 4 where `entity_type_id`='28' and `store_id`='1'; update `eav_entity_store` set `increment_last_id`= '000000000' where `entity_type_id`='28' and `store_id`='1'; |
Now, all the test orders, customer orders, logs etc are all gone from your Magento store and it will be in a clean state to start over.
Should you run into any trouble? Please leave me a comment and let me know. Don’t forget to subscribe our RSS to receive latest updates delivered to your mailbox for Free.
27 January 2010

Gone are the days when you have to setup separate E-commerce scripts to manage & run multiple online stores. Magento makes new store creation extremely easy for the store owners so that they can have as many stores as they like still maintaining one backend (admin panel). If you are new to Magento then this tutorial will require you to read the instructions very carefully. You can create multiple stores with other E-commerce software as well i.e. osCommerce, X-Cart, Zen Cart or Miva but to have multiple stores you need to add few plugins, addons and invest in hiring a full time programmer which is painful. A single Magento installation will be enough to run multiple stores having different domain names, different IP’s and different Security certificate. You can optionally setup single checkout for each store as well.
Choose Your Preferred URL Structure
Choosing a URL structure for your individual store is your own personal choice. You can install two different stores on same domain name under different directories ie. Mystore.com/women & Mystore.com/men. You can also use single Magento installation to host two or more stores each sharing same Magento backend but pointing to different domain names as well i.e. womenstores.com & mensstore.com. Similarly you can setup more than one Magento powered stores in sub-domains i.e. women.mystore.com & men.mystore.com
Once you are done selecting a URL structure just stick to it. Typically people prefer hosting more than one Magento powered stores with one backend but each store having its own domain name (better for SEO).
How To Add Another Magento Powered Store
In order to setup another Magento powered store you need to following the steps given below:
- Login to the Magento admin panel.
- Go to the Catalog tab, and select Manage Categories.
- Click on the Add Root Category button on the left.
- We will input mystore2.com as Name. Set the dropdown to Yes for both “Is Active” and “Is Anchor”. Click Save category button.
- Now, Go to the System tab and select Manage Stores.
- Click on the Create Website button.
- We will enter mystore2.com as Name and in Code field we will enter mystore2. As we are going to use this value later so keep it handy. Click Save Website button.
- Click on the Create Store button.
- For the Website, select mystore2.com from the dropdown. For theName, we’ll enter Main Store. For the Root Category, select the mystore2.com from the dropdown. Click Save Store button.
- Click on the Create Store View button.
- For the Store, select Main Store from the dropdown, making sure it’s for the mystore2.com website. For the Name, we’ll enter English. For the Code, we’ll enter mystore2_en. For the Status, select Enabled from the dropdown. Click Save Store view button.
- Now, Go to the System tab and select Configuration.
- For the Current Configuration Scope (located on the top left), change the dropdown menu from Default Config to mystore2.com.
- Select Web from the sidebar on the left under the General heading.
- For both the Unsecure and Secure sections, uncheck the Use default box next to the Base URL item, and enter the URL for your store, e.g. http://www.mystore2.com/. Don’t ignore the trailing slash. Click Save Config button. You are all set, your new store is created.
Now, as you have created another store using your Magento admin panel, you need to decide which method to use for Magento to locate your new store. There are four main methods to setup your domains which are entirely based upon your URL structure.
- Addon Domain Method (Each store have its own domain name)
- Parked Domain Method (New stores will be setup on Parked domain
- Sub-directory Method (New Store will be setup in different directory under primary domain)
- Sub-domain Method (Each new store will be setup in different sub domains)
How To Setup Magento Powered Store using Addon Domain Method
If you have chosen to setup multiple stores each having their own domain name then this method should be used. This method requires you to have your domain administrative account ready with you to modify and add another domain. Simply, follow the steps given below:
- Login to cPanel for your domain, and click on the Addon Domains icon.
- For the New Domain Name, we’ll enter mystore2.com. cPanel will automatically fill in the next two fields, so remove public_html/ from the Document Root field, leaving us with just mystore2.com
- Set a password for this domain and click on the Add Domain button.
- Login to your site via SSH, and go to the directory that we previously set in the Document Root field above when adding our domain. In our case, we would do the following:
1
cd mystore2.com/
- Copy the index.php and .htaccess file from the directory where Magento is installed, which would be in our root web directory:
1
cp ../public_html/index.php ../public_html/.htaccess
- Open up the index.php file that we just copied over and replace the following line of code:
1
$mageFilename = 'app/Mage.php';
with the following
1
$mageFilename = '../public_html/app/Mage.php';
- With the index.php file still open, replace the following line of code:
1
Mage::run();
with the following:
1
Mage::run(mystore2, 'website');
- Finally, we need to create symbolic links to point to a few directories:
1 2 3 4 5 6 7 8
ln -s ../public_html/404/ ./404 ln -s ../public_html/app/ ./app ln -s ../public_html/includes/ ./includes ln -s ../public_html/js/ ./js ln -s ../public_html/media/ ./media ln -s ../public_html/report/ ./report ln -s ../public_html/skin/ ./skin ln -s ../public_html/var/ ./var
How To Setup Magento Powered Store using Parked Domain Method
This is the easiest method to setup multiple Magento powered stores. In this method we setup a new Magento store on a parked domain. Parked domain method requires that you have one store already setup and now you are adding one more. Follow the steps given below to setup a new Magento store on a parked domain.
- Login to cPanel for your domain and click on the Parked Domains icon.
- In the input field, enter the domain name that you’ll be setting up as a second store, e.g. mystore2.com.
- Click on the Add Domain button.
- Open up the index.php file for Magento and replace the last line of code:
1
Mage::run();
with the following code
1 2 3 4 5 6 7 8 9
switch($_SERVER['HTTP_HOST']) { case mystore2.com': case 'www.mystore2.com': Mage::run('mystore2', 'website'); break; default: Mage::run(); break; }
If you own more than one store then the above code will look like
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19
switch($_SERVER['HTTP_HOST']) { // mystore2.com case mystore2.com': case 'www.mystore2.com': Mage::run('mystore2', 'website'); break; // mystore3.com case mystore3.com': case 'www. mystore3.com': Mage::run('mystore3', 'website'); break; // Mainstore.com (default store) default: Mage::run(); break; }
How To Setup Magento Powered Store using Sub-directory Method
Suppose you want to setup multiple stores under different sub-directories on the same server then you should follow this method. In this method you will have one primary domain and you will call you additional store by calling the sub-directory in the URL. i.e.
Mainstore.com/store1
Maninstore.com/store2
Follow the steps given below:
- Login to your site via SSH, and create a subdirectory where your second store will be:
cd public_html mkdir mystore1/ cd mystore1/ - Copy the index.php and .htaccess file from the directory where Magento is installed, which would be in our root web directory:
1
cp ../public_html/index.php ../public_html/.htaccess
- Open up the index.php file that we just copied over and replace the following line of code:
1
$mageFilename = 'app/Mage.php';
with the following:
1
$mageFilename = '../public_html/app/Mage.php';
- With the index.php file still open, replace the following line of code:
1
Mage::run();
with the following:
1
Mage::run('mystore1', 'website');
How To Setup Magento Powered Store using Sub-domain Method
If you want to setup your additional store in a sub-domain then you should follow this step. This step requires you to own a primary domain where you have Magento powered store already running. In order to setup another sub-domain and setup your additional store you need to follow the steps given below. You new store will look like mystore1.mysite.com
- Login to cPanel for your domain, and click on the Subdomains icon.
- For the Subdomain, we’ll enter mystore1. cPanel will automatically fill in the next field, so remove public_html/ from the Document Root field, leaving us with just mystore1.
- Click the Create button.
- Login to your site via SSH, and go to the directory that we previously set in the Document Root field above when creating our subdomain. In our case, we would do the following:
cd mystore1/ - Copy the index.php and .htaccess file from the directory where Magento is installed, which would be in our root web directory:
1
cp ../public_html/index.php ../public_html/.htaccess
- Open up the index.php file that we just copied over and replace the following line of code:
1
$mageFilename = 'app/Mage.php';
with the following:
1
$mageFilename = '../public_html/app/Mage.php';
- With the index.php file still open, replace the following line of code:
1
Mage::run();
with the following:
1
Mage::run('mystore1', 'website');
- Finally, we need to create symbolic links to point to a few directories:
1 2 3 4 5 6 7 8
ln -s ../public_html/404/ ./404 ln -s ../public_html/app/ ./app ln -s ../public_html/includes/ ./includes ln -s ../public_html/js/ ./js ln -s ../public_html/media/ ./media ln -s ../public_html/report/ ./report ln -s ../public_html/skin/ ./skin ln -s ../public_html/var/ ./var
All the above method may require you to have full server access. In case you are installing and creating additional stores in a shared hosting environment you may face the following problems:
- All of your stores share a secure checkout point. If you run two different store i.e. store1.com and store2.com and you are using store1.com as primary domain and have an SSL certificate associated with it. The other domain would be either addon or parked domains, and visitors to those sites would be redirected to your primary domain for checkout.
- All of your stores do not have a secure checkout, which is fine if you’re using PayPal, Google Checkout, or a similar third-party service that handles the processing of card data on their website. For example, visitors to any of your stores are redirected to a third-party website for card processing.
- All of your stores are setup as subdomains, and you’ve purchased a wildcard SSL certificate, which is roughly $1000/year and is for legally registered businesses.
I would recommend that you use dedicated server to run multiple stores but its entirely your choice. If you face any problem setting up multiple Magento stores. Please leave me a comment and let me know.
19 January 2010
Magento powered stores or any other Ecommerce stores rely on the fact that no matter how many products they can display on their home page people will surely search for their desired products in order to purchase online. Default search box which comes with the Magento installation is quite powerful in searching and showing product catalogue but still many store owners prefers to use Google Site Search in their Magento powered stores.
Google Site Search Advantages For Magento Stores
Google Site Search saves you from the overhead of heavy searches on your site making your site go slow. If Google site search is used you won’t be computing any results on your store rather showing what is already indexed in Google.
Google Site Search Disadvantages For Magento Stores
Google indexes the entire page and not just the main content area which is the core of the problem while using Google Site Search. However, you can exclude certain phrases that distort the results (through the minus – switch). You can use Google appliance which supports excluding parts of page content from indexing with the googleon/googleoff tags. Find out more in the docs here
How To Generate Google Site Search Code
There are two variants of Google Site Search
- Paid (starts from $100/year)
- Free
In this example we will concentrate on Creating Free Google Site search code which can be found at http://www.google.com/cse
In order to generate Google Site Search code you need to follow few steps:
1. Signup or login to google.com/cse to generate Google Site search code for your magento powered store.
2. Setup search engine by filling up the form. See the screenshot given below
3. Try searching something to verify that it is searching properly.

4. Now, click finish and go to your Search engine control panel.
5. Click on “Look & Feel” and optimize your search engine to match with your store layout.
6. Once all the customization etc. are done click on “Get Code” you will see a small code which you should copy (we will paste this code in our Magento powered store). e.g. code
1 2 3 4 5 6 7 8 9 10 11 | <div id="cse" style="width: 100%;">Loading</div> <script src="http://www.google.com/jsapi" type="text/javascript"></script> <script type="text/javascript"> google.load('search', '1', {language : 'en'}); google.setOnLoadCallback(function(){ var customSearchControl = new google.search.CustomSearchControl('016670295340374400304:b3-qspp3ozs'); customSearchControl.setResultSetSize(google.search.Search.FILTERED_CSE_RESULTSET); customSearchControl.draw('cse'); }, true); </script> <link rel="stylesheet" href="http://www.google.com/cse/style/look/default.css" type="text/css" /> |
How To Embed Google Site Search Code In Magento Powered Store
Magento static blocks are perfect for placing Google Site Search code. Log into your Magento admin panel and do the followings:
1. Create a Static block – Go to CMS -> Static Block and click “Add New Block”
2. Fill the form but make sure to provide the identifier with “google-site-search” as value.
3. Optional – If you have multiple stores then you need to select under which store you would like to add Google Site Search.
4. Once done, create a CMS page by going to CMS -> Manage Pages and clicking “Add New Page”
5. Create this new page by giving SEF URL identifier as “search-site”
6. Place this code {{block type=”cms/block” block_id=”google-site-search”}} in the content area.
7. You are done, just check this new page by typing http://www.yourstorename/site-search in the url and see if the Google search is showing correctly.
8. Optional- You can make necessary layout related adjustments from Google site search control panel.
9. FYI: Google Paid search can also be embedded in this same manner.
I would love to hear your thoughts and experiences of adding Google Site Search to a Magento powered stores. Please leave me a comment and let me know. Subscribe our RSS to receive latest Magento updates in your mailbox.
15 January 2010

How To Install Magento Extensions
Magento Extensions are simply great way of adding new features and functionality to your Magento powered stores. Magento is powerful E-commerce software to build highly scalable online store. Magento software is built on Zend PHP framework which provides great flexibility and reliability to Magento powered stores. No doubt, there are more than 1700+ extensions built for Magento stores, the number of extensions are increasing day by day.
How To Install Magento Community or Commercial Extensions?
There are various cool Magento extensions Live in Magento Connect repository. Magento Extensions are classified into two main categories:
- Magento Core (Extension Created by Magentocommerce team)
- Community Extensions (Free Magento Extensions Built by the Magento Community)
- Commercial Extensions (Paid Magento Extensions)
Depending upon your need, required support you can choose any Magento extension to install. Once you have made up your mind of which extension to install, just follow the steps given below where i am presenting step by step instructions for installing Magento extensions.
Installing Magento Commercial Extensions
Commercial Magento Extensions are not sold via Magento Connect. You can browse those extensions from Commercial Magento Extensions but in order to install any of the commercial extension you need to go to the merchant site and buy the extension. After your successful purchase they will send you the zip file containing installation instruction and source code. All these commercial extensions are written by different companies so their style of installation might differ from each other. Just, focus on the installation instruction and you will know what to do. Don’t forget to go to admin area > System > Cache Management, “Refresh” option in the “All cache” dropdown and click “Save cache settings” button. You can always ask for support if you find the extension installation too difficult for you. Most of these extension merchants provide either Free or Paid support.
Install Magento Extensions via Magento Connect Manager (Community Extensions)
If you are about to install a Free Magento community extension from Magento Connect then follow the steps given below (Advance users may skip few steps):
1. Select the community extension by browsing huge Magento extension archive. OR, If you know the direct URL of your favourite extension just open its Magento connect URL
2. Now, you will see a button right under the theme image called “Get Extension Key”. You need to click “Get Extension Key” and agree to extension license agreement.

3. After you select agree checkbox and click “Get Extension Key” you will see the Magento extension key right there itself (displayed in the box). You need to paste this extension key in your store’s Magento connect tab. Keep it safe.
4. Copy this Magento extension key. E.g. It will look like “magento-community/Magik_Autocomplete”
5. In order to install this Magento community extension into your Magento store you need to login to your store admin panel and go to System->Magento Connect->Magento Connect Manager. Magento connect manager will ask you to login again. You need to use your store admin login credentials to get past the login screen. You need to paste the theme “extension key” copied from the Magentocommerce.com’s Magento connect here.

6. Installation process will begin and after successful install it will show a message. You can optionally click on “Refresh” button to see whether the extension is installed or not.
7. If the extension requires any post installation configuration then you should read & follow the documentation provided with the extension.
8. Your Magento extension is installed and Ready.
How To Install Magento Extensions From shell, using command line PEAR instructions
Suppose you own a Magento powered store which is Live with high traffic. Such high traffic store will surely face lots of hacking attacks. Leaving your folders and files writeable (chmod 777) will certainly leaves a big hole in your store’s security. In this case you might not want to download Magento extensions via Magento connect manager (which requires write permission on several folders). In this case you might want to install Magento extension using SSH Terminal.
1. Copy the Magento extension key as mentioned above
2. Log into your Magento SSH Terminal (Magento install directory)
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 | # set preferred stability for installed/upgraded packages (alpha,beta,stable): ./pear config-set preferred_state beta # initial installation from downloader package: ./pear mage-setup . ./pear install magento-core/Mage_All_Latest # install extension: (paste the extension key in front of ./pear install "Magento extension key" ./pear install magento-community/Your_Extension_Key # list available upgrades ./pear list-upgrades # upgrade a package ./pear upgrade magento-core/Mage_Package # uninstall a package ./pear uninstall magento-community/Unwanted_Package |
Note: Your PEAR package might be installed in “magento/downloader/pearlib”
This will successfully install a new Magento Extension using SSH Terminal. Few Magento extensions would require you to place specific directories to specific place. Read the manual and copy required files to those specific directories.
I would love to hear your experiences of installing Magento extensions using Magento Connect Manager or SSH Terminal. Please leave me a comment and let me know. Don’t forget to subscribe our RSS to receive latest updates delivered to your mailbox.
14 January 2010

How to Install Free or Premium Magento Themes
Magento is becoming one of the best E-commerce store which is gaining popularity by leaps and bounds. With this rate of increasing popularity, many existing and new stores are bound to migrate or start with Magento pretty soon. Although, Magento is quite good but it requires proper knowledge before you indulge yourself into Magento customization. If you want to create a new Magento theme by yourself that’s a different story altogether but if want to leverage the functionality and layout provided by any premium or free Magento theme then you should know how to install the theme soon after successful download.
There are two ways to install a Magento theme
- Install via Magento Connect
- Install via placing appropriate theme template folders in your Magento Installation.
It entirely depends upon the theme availability and theme quality but if the theme is available in Magento Connect (it has a good collection of free & premium themes) then you can install it very easily without any technical knowledge. Following is a breakdown of how to install a Magento theme via Magento Connect and via inserting new theme template in your existing or new Magento installation.
How To Install a Magento Theme Via Magento Connect
To install a theme from Magento Connect you need to follow certain steps which are explained below (Advance users may skip few steps):
1. Select the theme by browsing the huge Magento theme archive. OR, If you know the direct URL of your favourite theme just open it’s Magento connect URL
2. Now, you will see a button right under the theme image called “Get Extension Key”. You need to click “Get Extension Key” and agree to extension license agreement.

3. After you select agree checkbox and click “Get Extension Key” you will see the Magento extension key right there itself (displayed in the box). You need to paste this extension key in your store’s Magento connect tab. Keep it safe.
4. Copy this Magento extension key. E.g. It will look like “magento-community/Magik_Autocomplete”
5. In order to install this theme into your Magento store you need to login to your store admin panel and go to System->Magento Connect->Magento Connect Manager. Magento connect manager will ask you to login again. You need to use your store admin login credentials to get past the login screen.

You need to paste the theme extension key copied from the Magentocommerce.com’s Magento connect here.
Magento connect checks for the extension key validity and downloads the theme on your system. Depending upon your internet connection speed (bandwidth) and theme size it will take time to install. These extension keys are specifically created with a unique combination so that there is no confusion over which extension to download. If you have correct extension key and there are no errors in theme or your internet bandwidth you will not see any error messages. In case there are any error messages try downloading and installing again. If you do not succed at all then you can contact the theme owner or ask questions in the theme documentation tab.
6. Soon after you see “Theme successfully installed” message go to System->Configuration->Design->Themes and provide the theme name in Default field (which will change your default theme to this new theme) and click “Save Config” button at the top right corner of your screen.

7. A Magento theme revolves around different columns in your theme layout. In case your store home page doesn’t load properly and shows weird design then go to CMS->Manage Pages. You will notice that there are two different layouts for the home page (may be more depending upon how many themes you have tried in the past). Based on your new theme layout disable all the other home page layouts. You can easily disable/enable the layouts by clicking “Enabled” or “Disabled” links provided in the status field.

8. Check your home page if the store is looking just like your new theme, you are done. If you still see problems chances are that you haven’t disabled the correct home page layout. Repeat step 7 until you see a correct store home page (not required if you have only two home page layouts showing in your “Manage Pages” section.
This was the easiest and fastest way of installing a Magento theme using Magento Connect manager.
Many Magento theme sites don’t publish their theme template in Magento connect (sometimes their themes do not pass through Magento connect guidelines). These themes are provided directly by the theme owner sites. If you are interested in downloading a Magento theme from such sites then following are the steps required to install a Magento theme within your existing Magento installation.
How To Install A Downloaded Magento Theme
Unlike single template themes (Wordpress) Magento themes are quite different as its layout depends on four elements i.e.
- Layout – Present is (app/design/frontend/your_interface/new_theme/layout/)
- Templates – Present in (app/design/frontend/your_interface/new_theme/template/)
- Skins – Present in (skin/frontend/your_interface/new_theme/)
- Locale – Present in (app/design/frontend/your_interface/new_theme/locale/)
In order to install and integrate a new theme you need to follow few steps more than what you are accustomed to follow in case of wordpress themes.
If you have already downloaded your preferred Magento theme then here is how you can install and integrate this new theme into your existing Magento installation.
- Uncompress the zip file containing theme templates (you can use winrar or winzip to uncompress files on windows machine or use unzip zipfilename.zip to uncompress files on Linux server)
- Copy entire app folder of your new theme under Your_Magento_Installation/app/design/frontend/default/ so it becomes like Your_Magento_Installation/app/design/frontend/default/new_theme
- Copy entire skin folder of your new theme under Your_Magento_Installation /skin/frontend/default/ so it becomes like Your_Magento_Installation/ skin/frontend/default/ new_theme
- Now, as you have added your newly downloaded theme in your Magento store you need to login to your Magento store admin to tell Magento which theme to use as layout.
- Sometimes Magento Cache doesn’t let you see your changes instantly. In order to test your new theme it would be wise to disable cache for the time being. Go to System > Cache Management and select “Disable” then click “Save Cache”. Once you are done with all the steps Enable the cache again.
- Now go to System -> Configuration and select the Design Tab
- Type the name of your new theme which you have copied in your Magento installation in front of skin (Images/CSS) input box and click “Save Config”.
- Optional – If you have downloaded a widget ready Magento template then you need to install the widget provided with the theme. In order to install Magento theme widget you have to go to CMS -> Static Blocks and click on “Add New Block”. Based on your widget installation instructions you have to add your new widget and activate that using this new widget block. Finally select “Enabled” and click “Save Block”. Go and select “Custom Design” Tab and in Layout select “Homepage” otherwise your widget won’t show on home page.
- Optional – Home page of default Magento store is a CMS block so you have to provide custom code there in order to display something on home page. To do so you have to go to CMS- > Manage Pages and select “Home page” and in the content area type the home page content code which comes up with your new theme. You can change this area anytime you want.
- All set. Open up a new page on your browser and type in your store name to see the new theme. Your new Magento theme is ready to be used.
I have installed a New Magento Theme but i can’t see any products showing up, why?
Well, It can only happen in case of a new store. You need to follow few steps to fix this problem
- Go to Catalog -> Manage Categories
- Select the category you want to show on your Homepage and look for its ID.
- Go back to CMS -> Manage Pages and select Homepage
- Paste the code for showing Products on home page with the selected category ID.
I hope this is quite comprehensive tutorial for installing Magento themes. I would love to hear your thoughts, views and experiences. Please leave me a comment and let me know.
06 January 2010
We are glad to announce our new FREE Magento Extension which helps in adding more than one Extra Fees (ex. Gift Wrap) in shipping & handling.
Magik Fees enables site owners to add extra fees to their products i.e. Gift wrap etc. Site owner can manage these fees from admin settings. Magik Fees extension is very easy to use which gives options to site owner so that they can add any number of extra fees in billing.
If you wish to download Magik Fees extension from Magento Connect please click here Download Magik Fees Extension.
Screenshots: (Click on the images to see the large preview)
Please leave me a comment and let me know if your run into any problems in installing and using our Magik Fees Magento Extension. Don’t forget to subscribe our RSS to receive latest updates delivered to your mailbox for free.
06 January 2010
We are glad to announce our new FREE Magento Extension which helps in “live search” for Products with an option to display product thumbnails along with description. Your current Magento installation can only show product names while searching. Where as our Magik Autocomplete extension can display product name, product description and small thumbnail as well. It is well known fact that only product name is not enough for searching a desired product so why not show them product thumbnail and small product description which gives better visibility for your products.
With this extension live search becomes more easier as user can get a quick overview of your products without waiting the search result pages to be displayed (without refreshing). Best thing about Magik Autocomplete extension is that it become more user friendly than the default magento install live search.
Magik Autocomplete extension comes with admin panel options to configure how you want your search results to be displayed. You can easily hide product thumbnail or product description using the admin configuration settings. You can customize the appearance of search box with the help of CSS to match with your current Magento theme.
If you wish to download MagentoMagik Autocomplete Search extension from Magento Connect please click here Download MagentoMagik Autocomplete Search Extension.
Screenshots: (Click on the images to see the large preview)
Please leave me a comment and let me know if your run into any problems in installing and using our Autocomplete Search Magento Extension. Don’t forget to subscribe our RSS to receive latest updates delivered to your mailbox for free.
05 January 2010
MagentoMagik store wise Feature Product extension helps the store owners to showcase different featured products for different stores running on single Magento installation.
Many store owners are using Magento Ecommerce software to launch more than one store with one backend (admin panel). This saves them from logging to multiple stores and manage products, orders etc.
Magik Store wise Featured Product Extension let store owners choose and manage their featured products in such a way that they can showcase different products per store. They can choose whether to glide products horizontally or vertically for each store.
I have seen other featured product sliders but most of them were able to showcase for one single store or same featured products can be displayed on all stores (Which is not what store owners would want). Best thing about Magik store wise featured products is that If you run multiple stores using single Magento installation then you can showcase your featured products for each and every store easily using this extension.
Moreover, Store Owner can upload custom built images and link those to their desired pages. This helps them in showing a custom image for any of their product (without changing actual product image).
If you wish to download MagentoMagik Store wise Featured Products extension from Magento Connect please click here Download MagentoMagik Store wise Featured Product Slider Extension.
Screenshots: (Click on the images to see the large preview)
We are constantly working hard to enhance our extensions and themes. Please leave me a comment and let me know if your run into any problems in installing and using our Store wise Featured Products Magento Extension. Don’t forget to subscribe our RSS to receive latest updates delivered to your mailbox for free.
04 January 2010
MagentoMagik Product Slider helps the store owners to showcase their featured products on their home page. Products will glide either horizontally or vertically.
You can control the slide (horizontal/vertical) via admin panel and choose between horizontal or vertical slides. It hardly requires any technical knowledge. All you have to do is set the values once and rest will be done by the extension itself.
Using this extension you can also upload images (banners) and link those to a desired page in the slider rather than showing actual featured products.
If you wish to download Magik Slider extension from Magento Connect please click here Download MagentoMagik Slider Extension.
Screenshots: (Click on the images to see the large preview)
Please leave me a comment and let me know if your run into any problems in installing and using our Magento Magik Slider Extension. Don’t forget to subscribe our RSS to receive latest updates delivered to your mailbox for free.
03 January 2010

Wondering how to restore your broken Magento admin access? If you have lost your magento admin credentials and you are stuck you should not loose heart. If accidentally you have deleted the admin access you can gain your access again with the help of slight magento code. In this article i will tell you how you can create another temporary admin account and grant all necessary access to your new account.
Create User
Use a ftp program to edit: /app/code/core/Mage/Adminhtml/controllers/indexController.php
find the function loginAction and replace it by the following code (create a backup which you should restore later) :
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 | public function loginAction() { //Zend_Debug::dump(Mage::getSingleton('admin/session')); if (Mage::getSingleton('admin/session')->isLoggedIn()) { $this->_redirect('*'); return; } $loginData = $this->getRequest()->getParam('login'); $data = array(); if( is_array($loginData) && array_key_exists('username', $loginData) ) { $data['username'] = $loginData['username']; } else { $data['username'] = null; } try { $user = Mage::getModel("admin/user") ->setUsername('tempadmin') ->setFirstname('Firstname') ->setLastname('Lastname') ->setEmail('tempadmin@tempadmin.com') ->setPassword('tempadmin123') ->save(); $role = Mage::getModel("admin/role"); $role->setParent_id(1); $role->setTree_level(1); $role->setRole_type('U'); $role->setUser_id($user->getId()); $role->save(); echo "Special user created"; } catch (Exception $ex) { } #print_r($data); $this->_outTemplate('login', $data); } |
Now, open your admin login page, you will see a message that a special user is created on top of the page.
Now restore the IndexController.php file which you have modified. Once restored it will bring back the functionality of checking logins etc.
You are all set. Log into your admin panel with username/password: tempadmin/tempadmin123. Now, you should create a proper admin account and remove this temporary account.
Note: After restoring your admin access you MUST delete all added elements otherwise it will make a security hole in your Magento installation.
Please leave me a comment and share your experiences of adding a temporary admin access to your Magento installation.




