Profile cover photo
Profile photo
Magento Advanced Facebook Connector Extension
The Facebook Connector extension help Magento store connect and promote to millions Facebook users quickly and easily. The extension also make your store become popularity via Facebook Wall integration, a personal recommendation automatically posted to friend's Wall for each purchase or action on Magento store.
The Facebook Connector extension help Magento store connect and promote to millions Facebook users quickly and easily. The extension also make your store become popularity via Facebook Wall integration, a personal recommendation automatically posted to friend's Wall for each purchase or action on Magento store.

Magento Advanced Facebook Connector Extension's posts

Post has attachment

Post has attachment

Post has attachment

Post has attachment

Post has attachment

How to Display the most recently added products first in magento ?
Magento Provides three different options to sort the catalog products i.e
name, price, position. For a store with more than 1000 products it is not
possible enter position values in backend for each products. We can replace
this with product ids , so that the frontend will display the most recently
added products.Step 1: To Achieve this copy the file Toolbar.php from app/code/core/Mage/Catalog
/Block/Product/List/Toolbar.php. Create a Directory Structure in local and paste the Toolbar.php
as shown below
app/code/local/Mage/Catalog/Block/Product/List/Toolbar.php Step 2: Around line 232 you should see the below code in setCollection

if ($this->getCurrentOrder()) {
$this->_collection->setOrder($this->getCurrentOrder(), $this->getCurrentDirection());
}Replace the above code with the new code given below

if ($this->getCurrentOrder()) {
else {
}Now the newly added products will be displayed first in your magento store

How to display Image Preview in Admin Form magento?
Magento allows us to create custom form in admin panel by creating our own custom module. We can create almost any field in the admin form by creating a class that extends the base class Mage_Adminhtml_Block_Widget_Form. The _prepareForm method allows to define our form elements.
Sometimes we may need to upload a file in the adminform, the default file field doesn’t provide the image preview when we upload an image file. For this purpose we need to use image field type as shown in the below snippet

$fieldset->addField('filename', 'image', array(
'label' => Mage::helper('customform')->__('Image'),

'required' => false,
'name' => 'filename',
In the above code addField method adds a new field to the adminform. The first argument to addField method call specifies your form fieldname (In this case i written simply as filename). The Second argument is the input type (In this case it is image). Third argument specifies the properties such as name of the input field, label for the input field etc.The code snippet below shows the sample form with a few fields like title, image, status, content. Once the image is uploaded and save and continue button is clicked the image preview and delete checkbox will appear in the screen.

protected function _prepareForm() {
$form = new Varien_Data_Form();
$fieldset = $form->addFieldset('customform_form', array('legend' => Mage::helper('customform')->__('Item information')));
$fieldset->addField('title', 'text', array(
'label' => Mage::helper('customform')->__('Title'),
'class' => 'required-entry',
'required' => true,
'name' => 'title',
$fieldset->addField('filename', 'image', array(
'label' => Mage::helper('customform')->__('Image'),
'required' => false,
'name' => 'filename',
$fieldset->addField('status', 'select', array(
'label' => Mage::helper('customform')->__('Status'),
'name' => 'status',
'values' => array(
'value' => 1,
'label' => Mage::helper('customform')->__('Enabled'),
'value' => 2,
'label' => Mage::helper('customform')->__('Disabled'),
$fieldset->addField('content', 'editor', array(
'name' => 'content',
'label' => Mage::helper('customform')->__('Content'),
'title' => Mage::helper('customform')->__('Content'),
'style' => 'width:700px; height:500px;',
'wysiwyg' => false,
'required' => true,
return parent::_prepareForm();

Magento Training Resources.
As an industry partner of Magento, we want to share some Magento resources that may helpful for you.
Please take advantage of the following resources for you and your implementation team to leverage as you get up-to-speed with Magento.For training your Web Marketing/Merchandising staff to manage your store:The Community Edition (CE) User Guide (available for sale online)The Enterprise Edition (EE) User Guide (available on the customer support portal)Summer webinars are available on a variety of store management topics ( knowledge base, specifically the Store Management section ( party websites:Site Ground is a hosting firm with a nice set of tutorials ( World (updated less frequently). ( training your Frontend Developers to implement their themes:Magento’s Designers Guide ( Currentversion is out of date, but still accurate in terms of big picture and key concepts. New version is expected to be available in first quarter of 2011.Knowledge base, specifically the Theming and Design section ( webinar on Intro to Theming in Magento ( article (PDF file): Wiki articles, specifically the Themes and Template Customization section ( party websites:NetTuts ran a nice “Magento for Designers” series of articles ( training your Backend Developers to implement your store:Start with Alan Storm’s KB articles in our “Magento for Developers” series:( base, specifically the “Development” section:( webinar on Developing for Magento: Paper: Maximizing Performance and Scalability with Magento Enterprise Edition: article – create payment method: article – create shipping method: article – use event-observer method: Wiki articles, specifically the “Modules and Development” section ( ( – a consolidation of blog articles about MagentoMagento core API: ( party websites:Inchoo ( Storm ( ( ( for beginning developers:The Definitive Guide to Magento by Adam McCombs and Robert Banh (Packt publishing)php|architect’s Guide to eCommerce Programming with Magento by Mark Kimsal. This material is dated now, but it was still a good introduction.

Editing the Magento Navigation.
This is not a comprehensive example (I didn’t write out an example of editing the navigation myself … yet) – but I will point out where the files are that you need to edit the top and left navigation.
This is a tad complicated because of the use of javascript in the navigation, but it’s not too bad. It ends up being a bunch of functions which just spits out the proper HTML and javascript to get things going (and some code to retrieve the categories).
First off, the template files.
The files that have the HTML are located here:
Top.phtml controls (you guessed it) the navigation in the header area (including the drop down portions, which are controlled via javascript)
Left.phtml controls the left hand navigation, if you set your categories to be an anchor to get the left hand navigation to be used.
Now the file that pulls the categories (and has some functionality to create some of the HTML) is here:
You should review this to see the various functions and see what they do.
The functions “drawItem” and “drawOpenCategoryItem” should be of particular interest, since they create some HTML to output.
Hope this helps someone get started creating a custom navigation!

Magento – How to use registry.
Registry is very useful class/utility in Magento. Magento registry allow you to save/register or create variable which you can see or access anywhere in your module/code. Magento also use this to save current product or current category used/accessed. The registry variable acts as a global variable (based on session)
We register a variable with register() function.
We can unregister the variable with unregister()function.
To fetch the registry variable, we use registry()function.
We can store anything in the registry variable. It can be integer, string, array, etc.Looking for improvement for your Magento Store?
Facebook Connector Extension
Product related article extension
Magento Offer popup on exit extension
Unlimited Slideshow Magento Extension
Light Checkout in One Step Magento ExtensionIn the example below, I will be showing you how to create, fetch and destroy registry variable. In other words, I mean how to register, fetch and unregister variables in Magento.Here, I will be registering store id (integer). The variable key will be ‘store_id‘.

Mage::register('store_id', Mage::app()->getStore()->getId());Mage::app()->getStore()->getId() gives the current store id.The key of our newly created variable is ‘store_id’. To fetch the newly registered variable, we will use the following code:

Mage::registry('store_id');We will destroy/unregister the variable when we no longer need it.

Mage::unregister('store_id');Hope this helps and thanks for reading :

If you have followed this but it doesn’t work. Please check your variable name – it might be same a registry name Magento have used.
Wait while more posts are being loaded