Currently browsing

Magento Model Code Generation

This is a quick one for advanced users, is a recent problem, I answered StackOverflow inspired.

Magento as well as about an abstract system as one of the advantages is the opportunity it presents metaprogramming. Drops action in a controller (which is the following code, you can define an internal function in PHP)

Magento – How to Add JQuery/Ajax Add-To-Cart

So, the thing Ajax and all being, I was hunting for a way to an item to add the car with a Ajax call in Magento. Recently, I noticed there was a module that apparently either did not I, but had not seen it or did not exist when I wrote this, so I hacked my way through it.

PHP is not my primary language – I'm from the ASP, ASP.Net, C # world, but Magento was convincing enough that I took the plunge. I'm sure there are many things I do better / differently than here, so if you could get some suggestions, I'm all ears!

magento – instantiation abstraction and Autoload

magento autoloadmagentos autoload functionalityIf you Aore at all familiar with object-oriented programming, the following line should you look for familiar. $customer_group = new Mage_Customer_Model_Group(); We, Aore instantiating an instance of the class Mage_Customer_Model_Group. However, if you were looking at the code base for Magento Mage_Customer_Model_Group you, AOD never a single …

How to override a Magento core block class

how to override block in magentomagento override blockThis tutorial will show you the proper method for overriding a Mage core class. This will work for Block and Model classes. Controllers are a slightly different story and for another tutorial. Some discussion on breadcrumbs: I will be overriding the Core file: …