Tuesday, January 10, 2012

Starting Magento Development

Dev Environment

I am using Komodo and DreamWeaver for development.

I did try the Zend Studio as an IDE (Magento is based on the Zend Framework), and the SVN plugin for Eclipse, but didn't find either particularity enjoyable to use. I have generally found there is a little more friction than we are used to with Visual Studio. It's often easier to get things done outside of the IDE. With Magento you have to create a copy of a file you want to override and put it in a different folder, so you spend a lot of time messing around in the file system, outside of the IDE.

References

The Magento forums are rubbish I'm afraid - no one replies to anything. It has taken me hours to figure some little things out. I would just say stick at it, the code can appear to be very fragmented, but as you get used to it you will appreciate how modular and extensible it is.

Good Blogs

http://www.westwideweb.com/wp/category/magento/

http://inchoo.net/category/ecommerce/magento/

http://activecodeline.net/

http://www.exploremagento.com/category/magento

Get Current Logged in Customer Info

Check if the customer is logged in then

Mage::getSingleton('customer/session')->isLoggedIn();


Get Current Customer Name

Mage::getSingleton('customer/session')->getCustomer()->getName();


You can Get Current Customer All Information

echo "<pre>"; print_r(Mage::helper('customer')->getCustomer()->getData()); echo "</pre>";


Ger Current Logged in Admin

Mage::getSingleton('admin/session')->getUser();

Monday, January 2, 2012

Magento Products Are Not Showing

Sometimes your added products from admin are not displaying at frontend magento store. These products dont list in categories either. In order to avoid this situation, follow these steps:

  • The products must be Visible in Catalog*.
  • The products must be Enabled.
  • Product must have a stock Quantity.
  • The product must be set to In Stock.
  • The product must be assigned to the target Category (if you want that product to list in that specific category).
  • If using multi-website mode (or if you imported the products through Data Flow), the products must be assigned to the target Website.
  • You must clear your Cache/Indexes, just to make sure.

*You may set Visible in Catalog/Search to display in Search as well.