How to change Default Sort Order Magento

Share
Posted on December 27th, 2011 | Posted by admin

I’ll be clear… Magento is not good as you could imagine. In fact sucks in so many ways.

Today i’m showing you one. There is no backend option to change the Default Sort Order in your product listing (catalog).

Lucky there is an easy solution.

The Toolbar

Look for the file toolbar.php located in:

/app/code/core/Mage/Catalog/Block/Product/List

Create the Local folder

Create the same folder structure in the local. Now the future upgrades will not affect your changes.

Should be like:

/app/code/local/Mage/Catalog/Block/Product/List

Edit the Toolbar

How to change the Price Range Magento

Share
Posted on December 27th, 2011 | Posted by admin

If you need to change the Price Range in your Magento catalog go to:

app/code/core/Mage/Catalog/Model/Layer/Filter/Price.php

Look for the line:

$range = pow(10, (strlen(floor($maxPrice))-$index));

Change the 10 for a lower / higher number.

Tested in the 1.4 version

Magento Country codes for table rate

Share
Posted on December 27th, 2011 | Posted by admin

I was getting mad trying to figure out how to know the Magentro Country Codes.

When you want to upload a Shipping Table Rate (csv file) you need to enter those codes in your file.

Looks like they don’t give the info in a easy way.

So I found a dirty solution but it works.

How to fast stock update Magento

Share
Posted on December 23rd, 2011 | Posted by admin

If you ever tried to import product stocks in Magento I’m sure you noticed is extremly slow.

Doesn’t matter how many fields you set in the CSV file it always takes the same time.

Digging arround I found this amazing code.

Create a CSV File

/var/import/updateStockLevels.csv

Place your CSV file like I wrote above.

You can add many fields but I would suggest 2 or 3 (to be faster)

qty
min_qty
use_config_min_qty
is_qty_decimal
backorders
use_config_backorders
min_sale_qty
use_config_min_sale_qty
max_sale_qty
use_config_max_sale_qty

Setting Up Featured Products In Magento

Share
Posted on December 8th, 2011 | Posted by admin

ecommerce shops feel the urge to showcase their special products or featured products either on their shop’s home page or category listing pages depending upon the requirement. Various ecommerce scripts have already developed this feature and you will see a dropdown or a radio button to mark a product as featured. Unfortunately, Magento doesn’t provide this option by default. There are numerous Magento extensions available which will do the job including our Featured product slider which creates the custom attribute called “featured” and shows on product catalog page (admin) but if you are looking for a extension free solution then read on.

Creating new custom attribute called “Featured”

First of all you will have to create a custom attribute called “featured”. Go to Catalog => Manage Attribute => Add New and enter “featured” as attribute code. Choose Scope as “Global” or choose as per your website. Under Catalog Input Type choose “Yes/No” (you can not change this once an attribute is created).

[* Click on Image to see large preview]