Display Image Category above 2 columns left page


The category banner (image) comes from template/catalog/category/view.phtml like this

if ($_imgUrl = $_category->getImageUrl()) { $_imgHtml = '<div class="category-image-container"><div class="category-image-container-inner"><p class="category-image"><img src="'.$_imgUrl.'" alt="'.$this->htmlEscape($_category->getName()).'" title="'.$this->htmlEscape($_category->getName()).'" /></p></div></div>'; $_imgHtml = $_helper->categoryAttribute($_category, $_imgHtml, 'image'); } first comment this

Then in template/page/2columns-left.phtml between<div class="main"> and <div class="col-left"><?php echo $this->getChildHtml('left') ?></div>

write the category banner code

<?php   
        $_category  = Mage::registry('current_category');
        if($_category){
         $_helper    = Mage::helper('catalog/output');

            $_imgHtml   = '';
            if ($_imgUrl = $_category->getImageUrl()) {
           echo   $_imgHtml = '<div class="category-image-container1"><div class="category-image-container-inner"><p class="category-image"><img src="'.$_imgUrl.'" alt="'.$this->htmlEscape($_category->getName()).'" title="'.$this->htmlEscape($_category->getName()).'" /></p></div></div>';
                $_imgHtml = $_helper->categoryAttribute($_category, $_imgHtml, 'image');
            }
        }
        ?>

This will show the category banner above the left column and the content.

How to remove index.php URLs in Magento


1) Login to admin section by using the URL

http://domain.com/index.php/admin

2) then go to “System >>  Configuration >>Web >> Search Engines Optimization”
Use Web Server Rewrites : YES

3) Go to “System >>  Configuration >>Web >>Secure”

Use secure URL Frontend: YES

4)Then create the .htaccess file under your the magento installed folder.

If the magento installed under document root ( /home/username/public_html) then add follogig rules into .htaccess file

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

and If the magento installed under /shop or directory then add the following rules into ” /home/username/public_html/shop/.htaccess ” file.

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /shop/
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /shop/index.php [L]
</IfModule>

Unable to process payment. Please contact the merchant as the shipping address provided by the merchant is invalid, and the merchant has requested that your order must be shipped to that address.


In Magento Community 1.7.0.2 you need to copy the file:
/app/code/core/Mage/Paypal/Model/Api/standard.php

to:
/app/code/local/Mage/Paypal/Model/Api/standard.php

and change line 238 from:
$request['address_override'] = 1;

to:
$request['address_override'] = 0;

cache problem in footer magento


copy

1 app/code/core/Mage/Page/Block/Html/Footer.php

to

1 app/code/local/Mage/Page/Block/Html/Footer.php

and just comment out the following lines:

1 //$this->addData(array(
2 //    'cache_lifetime'=> false,
3 //    'cache_tags'    => array(Mage_Core_Model_Store::CACHE_TAG, Mage_Cms_Model_Block::CACHE_TAG)
4 //));