magento

Magento upgrade from 1.4, 1.5, 1.6, 1.7, or 1.8 to 1.9

NOTE: this upgrade process works the same way for Magento version 1.4, 1.5, 1.6, 1.7, 1.8, and 1.9

As many magento users will know, Magento is no fun to work with-- mainly due to poor community support (the developers help paying customers; i.e. Magento Enterprise ... Only payed support there... Great for business but bad for the average or beginning user...)

Anyhow...

So here's how we do it.

MAKE A BACKUP!

You can skip this step all together, however, please make a backup of everything prior to beginning the upgrade.

Create a test environment somewhere on your server (preferably away from your production installation)

Tags: how-to magento magento upgrade

Pinterest: How to exclude images from being pinned via jQuery.

Say you have Pinterest setup on your site to allow pinning or saving of images. However, you obviously don't want this enabled for all images (ex: menu images, footer images, etc).

Here's how to exclude certain images from being recognized by Pinterest:

In Magento, you would add the following to your local.xml, under <reference name="head">:

Tags: jquery pinterest magento

Fix magento 1.9 price rules "Stop Further Rules Processing"

There's a bug affecting all magento 1.9 versions, that prevents users from applying multiple coupons to their order--even if "Stop further rules processing" is NOT selected.

Basically, a customer can only apply a single coupon to their order--no stacking of coupons works in Magento 1.9.

Here's the fix, you'll need modman and generate-modman installed:

Tags: magento

Easily manage magento extension installations with modman and generate-modman

Modman lets you install/uninstall magento extensions without the use of Magento Connect.

Why would you use modman?

Say you have an extension that doesn't use Magento Connect--where you upload it's contents manually. When you want to uninstall that extension, you have to tediously/manually search the installation files/folders and remove them by hand.

With modman, this is done for you perfectly--no more tedious labor.

Install modman

Let's first install modman.

1. Enable symlink support in magento: System > Configuration > Advanced > Developer , Under "Template Settings" > "Allow Symlinks" select "Yes"

2. Download and run the installer.

Tags: magento modman

Add "You Save" amount and percentage to Special Price in Magento

In order to display a "You Save" for "Special Price" products in magento--to make it look similar to amazon's price display--you can do the following:

Copy

app/design/frontend/base/default/template/catalog/product/price.phtml

to

app/design/frontend/default/YOURTEMPLATE/template/catalog/product/price.phtml

Then in price.phtml that you just copied, right above:


Insert:



$_savePercent = 100 - round(($_finalPrice / $_price) * 100);
$_saveAmount = number_format(($_price - $_finalPrice), 2);
?>
Tags: magento price display

Add memcached Support to Magento

After you successfully install memcached and pecl/memcached (memcached PHP support), you will next want take full advantage of it by enabling native support for memcached in magento.

NOTE: you must have memcached and pecl/memcached already installed. Otherwise your Magento installation will break if you try following this guide.

Ok... now that the warning is out the way. Here's how we do it...

Edit your local.xml


vi ./app/etc/local.xml

Add the following between

Tags: magento memcached Linux

Magento Google Shopping Setup aka Google Base aka Google Content aka Google Merchant

Here's a quick (and hopefully easy) tutorial on how to properly setup Magento with Google Base aka "Google Shopping" or "Google Content" .

I know there is very limited help for Google Base/Shopping for Magento Community Edition 1.6 and 1.7 (and nothing official exists on any lower versions)...

The interested fact is, Magento is knowingly supplying a broken extension with 1.6 and 1.7--i.e. there is no way it will work unless you hack the core code; as we will below.

Hopefully, the community edition will get a working extension soon, just like the Magento Go version.

Anyhow... on to self help!

Tags: magento google

Magento Google Analytics goals setup

Ok... let's get right into it...

We'll assume you already have google analytics setup and working with magento...

So... we want to add Google Analytics Goals so we can track what people are doing at the different steps of checkout.

Alright... here we go...

  1. Log into your Google Analytics account
  2. Click "Admin" at the top right (of the new version of Google Analytics)
  3. Click the name of your domain
  4. Click "Goals" tab--towards the middle of page
  5. Click one of the non used "+ Goal" links
  6. Now we fill in all the info...

Tags: magento google analytics

How to uninstall multipletablerates from magento

Multiple Table Rates (aka multipletablerates) was a very popular extension in the magento 1.3 and earlier days... However, after several magento versions this extension basically became completely unstable/buggy (this is normal as it only lists magento 1.1 compatability)... Even so, it still worked on magento 1.3 with a few minor bugs... Then later down the road other extensions came up (mostly paid) that provided similar functionality, plus some, and minus the bugs...

Tags: magento extensions

Magento Catalog Price Rules bugs

Magento's "Catalog Price Rules" was always a buggy experience, ever since magento 1.3... I don't know what's going with the development, but it's still buggy up to 1.4.1 ...

So here are a couple of fixes I found.

Magento 1.4.0.1:

source: http://www.magentocommerce.com/boards/viewthread/194930/#t245120

1. Open up Observer.php in /app/code/core/Mage/CatalogRule/Model/
2. Find the dailyCatalogUpdate() method
3. At the end of the method, before “return $this;”, add:
$this->applyAllRules( $this );
4. (Not sure if this step is necessary) Open up /app/code/core/Mage/CatalogRule/etc/config.xml
5. Find the crontab > jobs > catalogrule_apply_all area
6. Change
<cron_expr>0 1 * * *</cron_expr>

Tags: magento

Magento default sort order

In order to specify the default sort order of the product listing open up your 'catalog.xml' (this is tested in magento 1.4): desc To order products by a specific order, e.g. to order products by the order specified under category listing: set in your admin: yoursite.com/admin/system_config/edit/section/catalog/
Product listing sort by: Best Value
And for those wondering where 'category products' is... it's located here: /admin/admin/catalog_category/ (under "Category Products" tab, when you click on any category)
Tags: magento

How to add free shipping notice on product listing and product view in Magento

NOTE: This tutorial assumes you're using an extension that uses the "special_shipping_group" attribute... But you can also use this tutorial to output any attribute you'd like into the product view and product listing.

Ok... Say you're using the "special_shipping_group" attribute, to specify which products should receive free shipping.

You would, for example, add an attribute called: FREE SHIPPING

Make sure you also set this visible under product listing, and product view, or else it won't display.

Following, you will assign this attribute to all the products that are to use this "FREE SHIPPING" attribute.

Now...

Tags: Design magento attributes shipping free shipping display

Magento Featured Products Listing on Home Page

There are a few articles and extensions I've come across showing how to add "Featured Products" on the home page of Magento. The problem is that none that I have read, seem to fully tackle the issue of being compatible with Magento 1.4.x (Magento 1.4.0.1 at the time of this writing) AND fully using Magento's features while being fairly easy to implement (i.e. without adding complicated, unnecessary,redundant or outdated code)

Tags: magento featured products

Magento 1.4 toolbar error (How to properly upgrade to Magento 1.4)

In case you upgraded to magento 1.4, and noticed that your category listings that require pagination (page 1, 2, 3) no longer show, here's the fix...

1. copy the new 1.4 toolbar.phtml from

app/design/frontend/base/default/template/catalog/product/list/toolbar.phtml

and paste it into your custom theme

app/design/frontend/*/YOURTHEME/template/catalog/product/list/toolbar.phtml

(note: make sure you put this into your currently used theme directory. If you installed a theme via Admin-->System-->Design then get the name of the theme from there)

2. edit your app/design/frontend/*/YOURTHEME/layout/catalog.xml

Find:

<block type="catalog/product_list_toolbar" name="product_list_toolbar" template="catalog/product/list/toolbar.phtml">

Tags: magento

How to remove Yoast MetaRobots from Magento

In case you want to upgrade to magento 1.4, and have Yoast MetaRobots installed, you'll have to uninstall it first, since it's not compatible with 1.4.

Here's how:

1. uninstall it from magento connect
2. Remove the config xml file from /app/etc/modules/Yoast_Metarobots.xml
3. Remove the module files and directories from /app/code/community/yoast/Metarobots/
4.Clear your cache
SSH into your root magento directory and:

rm -rf var/cache/*

5. run this SQL query (easily done in phpMyAdmin)

DELETE FROM `eav_attribute` WHERE `eav_attribute`.`attribute_code` = 'meta_robots';
DELETE FROM `core_resource` WHERE CODE = 'metarobots_setup';

You should be good to go after this...

Tags: magento extensions

Magento 1.4 product-name quotes are converted to html and then escaped

After upgrading from magento 1.3 to 1.4, if your product headings used quotes " " or ampersands & , then magento may convert these into HTML and then escape that HTML counterparts hence showing e.g.:

"Thermo Balance" Tub & Shower Valve Rough In Valve

like:

&quot;Thermo Balance&quot; Tub &amp; Shower Valve Rough In Valve

The fix is to go into "view.phtml" and change:

            <h1 class="product-name">
               
<?php echo $_helper->productAttribute($_product, $this->htmlEscape($_product->getName()), 'name') ?>

            </h1>

to

            <h1 class="product-name">
               
<?php echo $this->htmlEscape($_product->getName())?>

            </h1>

Tags: howto magento

How to remove <br /> added by magento.

In case you're wondering why your product description is all spaced out, then that's because magento is adding automatic line breaks into the content description area...

To get rid of it... look for

nl2br

specifically in description.phtml you'll see

<div class="std">
   
<?php echo $this->helper('catalog/output')->productAttribute($this->getProduct(), nl2br($this->getProduct()->getDescription()), 'description') ?>

</div>

it should look like this after you take the nl2br out:

<div class="std">
   
<?php echo $this->helper('catalog/output')->productAttribute($this->getProduct(), ($this->getProduct()->getDescription()), 'description') ?>

</div>

Tags: magento code

How to remove Paypal Quick Checkout button from Magento when using Paypal.

If you disable "guest checkout" in magento -- and are using PayPal -- guest check is still possible via Paypal button--it will show below the "Proceed to Checkout" button.

In order to completely remove the possibility of Guest checkout, you'll need to alter the following:

app/design/frondend/default/YOURTEMPLATE/template/paypal/link.phtml

  • copy link.phtml to link-01.phtml or whatever
  • open/edit link.phtml and delete (or comment out) everything.
Tags: paypal magento