Magento - Moving Directory from Test to Live

Many Magento users try the application out first on sub-directory or test directory. A lot of times, moving an application from test directory to live directory can be hectic and time-consuming. Luckily, it is relatively easy to move Magento from one directory to another withing the same server. Backup everything. Update the unsecure / secure URLs via the Admin panel. System -> Configuration -> Click Web from the left menu. i.e.) Change http://www.mycompany.com/test/ to http://www.mycompany.com. When you save the new URLs through the Admin panel, it will show error messages after you're done. This happens because the Admin can't be redirected ...

Magento - Yahoo Analytics Conversion Code

Unlike other tracking codes, we need to put Yahoo Analytics Conversion code between <HEAD> and </HEAD> tags. Yahoo’s Instructions for the following code are: Copy the HTML code below and insert it between the <HEAD> and </HEAD> tags on your site’s conversion page(s). To pass a dynamic revenue value in the tag, you must modify your web pages accordingly. To add the Yahoo conversion tracking code in the Head tags, we need to look at the checkout layout configuration file: /app/design/frontend/your_interface/your_theme/layout/checkout.xml Find out which page layout it uses when an order is completed. i.e.) For one page checkout, look for this code: <checkout_onepage_success> <reference name="root"> <action method="setTemplate"><template>page/2columns-right.phtml</template></action> </reference> You can edit ...

Magento - AdWords Conversion Tracking

When you use Google AdWords to receive more traffic, don't forget to track the traffic. AdWords Conversion Tracking is a free tool to help you understand how many users actually buy products or services from you. Installing AdWords conversion tracking codes is pretty straightforward. Open the file /app/design/frontend/your_interface/your_theme/template/checkout/success.phtml. Find the following code in the file. <?php echo $this->__('Your order # is: %s', $this->getViewOrderUrl(), $this->getOrderId()) ?>. <?php else :?> <?php echo $this->__('Your order # is: %s', $this->getOrderId()) ?>. <?php endif;?> Add the following code under the above code. If your success.phtml is customized, add it at the end of the file. In most cases, it should ...

Magento Speed and Performance

Magento is one of the most flexible open-source e-commerce applications that comes with lots of desirable features for shopping-cart sites. However, due to these various functionalities, its performance can be a major issue. Magento provides helpful resources in its blog and forum to improve performance including database tuning and server configuration modification. But in many cases, these performance enhancements should be done through system administrators of your hosting company or would work only when you have a dedicated server. Read more about Magento Performance Improvement. An easier way to improve Magento website speed is to turn on GZip compression ...

Change Order of Blocks - ‘before’ and ‘after’ attributes

Use 'before' and 'after' block attributes to change the order of blocks. You can set the position of a block within a structural block by assigning the name of another block to either 'before' or 'after' attribute. For example, if you'd like to put 'Product Viewed' box below 'Cart' box on the right menu, you can define the layout XML files as follows: in catalog.xml <reference name="right"> <block type="reports/product_viewed" before="cart_sidebar" name="reports.product.viewed" template="reports/product_viewed.phtml"/> ... </reference> You can define block position at the very top or bottom by using before="-" or after="-".