Search This Blog

Thursday, April 26, 2012

Magento in admin html backend add a coloumn Action

Magento in admin html backend add a coloumn Action

magento add action coloumn in admin  grid

Code

$this->addColumn('action',
                        array(
                            'header'    =>  Mage::helper('Module')->__('Action'),
                            'width'     => '100',
                            'type'      => 'action',
                            'getter'    => 'getId',
                            'actions'   => array(
                                array(
                                    'caption'   => Mage::helper('Module')->__('Edit'),
                                    'url'       => array('base'=> '*/*/edit'),
                                    'field'     => 'id'
                                )
                            ),
                            'filter'    => false,
                            'sortable'  => false,
                            'index'     => 'stores',
                            'is_system' => true,
                    ));

Thursday, April 5, 2012

Magento Service Temporarily Unavailable The server is temporarily unable to service your request

Service Temporarily Unavailable The server is temporarily unable to service your request …..

There are two main reasons why you may get this error.

1. There is an actual problem with the server, resulting in the 503 error response. In this case, you should contact your hosting provider.

2. Your store has been put in maintenance mode. If Magento sees a file named maintenance.flag in the root directory, it will automatically redirect all requests to the default 503 error page. This can be used during upgrades, etc. to prevent users from accessing the store. The solution is, as already mentioned, to delete/rename the maintenance.flag file.

There might also be a good idea to create a more user friendly “maintenance page” than the 503 error, which is kind of misleading for customers.

Deleted file and removed cache.. and its working fine..

Magento use Tire Pricing or set rules for discuonts

Q
Tier Pricing for discunts

Answer
Hi,

Tier Pricing is a promotional tool provided by standard Magetno
It allows a store owner to price items differently for higher quantities.

1. In the Magento Admin Panel, navigate to Catalog > Manage Products.
2. Find the product that you want to add tier pricing to (or create a new product) and click Edit in the Action column.
3. Click on prices tab on the left
4. Click “add tier”

You will get tier tab with “web site”, “customer group”, “quantity”, “price”.
Make your choise. In price field you put price which makes 50% of your product cost. and this product will be sold with this discount provided that buyer puts in cart .....(make your choise in quantity tab) items.
More over you can stipulate the group of customers who are provided with the discount. For example - only registered customers.

If you want to spread and apply discount coupon you can have a look at GoMage LightCheckout for Magento it is one page checkout extension which is amoust bunch of useful extensions in one. By the way it is compatible with 1.5 Magento vesion.

Monday, April 2, 2012

magento custom form fields

In this tutorial, we are going to see all the different form fields we can use in admin forms.

Magento has many different type of field available by default, so lets see the syntax of using each of these fields. This tutorial is in continuation of the previous tutorial so the same classes will be used as in the previous post.
All the code’s written below are written in the class Excellence_Form_Block_Adminhtml_Form_Edit_Tab_Form inside the _prepareForm() function as shown in previous tutorial. All the different type of form fields available in magento are located in folder lib\Varien\Data\Form\Element

http://www.excellencemagentoblog.com/magento-admin-form-field

Friday, February 17, 2012

change address bar search to google

change address bar search to google
1. In Firefox type about:config in the address bar and press ENTER.

2. Locate and double-click the entry for keyword.URL

3. Set the value based on which search provider you would like to use for your address bar searches. Here are a few search strings you can use.

Yahoo: http://search.yahoo.com/search?p=

Ask: http://www.ask.com/web?q=

Bing: http://www.bing.com/search?ie=UTF-8&oe=UTF-8&sourceid=navclient&gfns=1&q=

Google: http://www.google.com/search?&q=

Tuesday, February 14, 2012

mysql IN query without changing the order and maintaining the input order

mysql IN query without changing the order
e.g
SELECT FROM emp WHERE (id in ('10001', '10004','10003','10025')) ORDER BY FIELD (id,'10001', '10004','10003','10025')
this will maintain the order of 1,4,3,5
instead of the regular 1,3,4,5