tags:

views:

102

answers:

3

Ok, magento is new to me, and in fact ecommerce site development itself is new.

Magento seems to be extremely difficult to get to grips with - I have spent 3 days now going round I'm circles trying to create a custom theme and modules.

The documentation is poor, the code and structure appears obfuscated - when will it get easier?!

Are there any specific tips or advice that you can offer for learning magento properly ? For any other developers out there - how long (full time development) did it take to start to make sense of magento and to get things done quickly?

+1  A: 

Magento is build upon Zend Framework. I think basic knowledge of ZF will get you af good head start.

Try have a look at 'ZendFramework in Action'. That's where i started with ZF.

ZFiA will probably give you a good insight into the MVC-pattern and directory-structure of ZF. This you should be able to project onto Magento.

And i'm currently working on 2 ZF projects. I have yet to do a Magento shop, but it's in the commings.

Played around with Magento, right after the release. And must say that there were lots problems just to get it to install and to perform good. So haven't been playing with it since. It's my impression that it's evolved since then, and the performance issues should be ironned out. Still not an application you should run on a 1-buck shared hosting.

Phliplip
+2  A: 

The first step towards getting anything done in Magento is to read the Magento Design Guide.

Once you are familiar with the XML/Block system, you can make changes to the design portion very easily. Once you're comfortable with that, you're going to want to take a look at every folder in your base Magento install. Each folder has a purpose, and having an understanding of what each one's function within Magento will help you when you decide to start making modules.

Alan Storm has a great tutorial for your first module here. I'd read that carefully and get the books that he suggested; they are great resources.

Finally, start tracing functions through the code. I basically have grep -R available at all times to find out where methods are defined so I can better understand what their capabilities are. Because of the size of Magento, sometimes that's the best way to find answers.

Good luck!

melee
+2  A: 

AS Phliplip said, have a understanding of the MVC pattern and the way Zend Framework implements those. Especially the Controller part, Model and View are handled differently.

Make sure you use a descent editor (e.g. eclipse+pdt) which allows you to click at any function and it will show you the source as well as setting up xDebug so you can travel though some code while its running and see the values of the variables.

Magento gets controlled by many config.xml files in each module which get merged to one big xml. So you need to understand how you setup a module and what Mage::getModule('yourmodul/xx_yyy') does. as well es Mage::getResourceModule(), Mage::helper(), Mage::getBlock()

Make sure you are 100% familiar with the class Varien_Object,... and become a fan of it :)

Try to understand the Magento Collection class which basicly wraps any mysql query returning more then one result

Get familiar with a the database eav model

When you are planning on altering the database,... you should make sure you understand the magento installer.

There is lot more.... it took me I don't know 6 month to get a good understanding of it...

butterbrot