Magento - How to get form input values when adding new product

I am trying to collect values of form fields when adding a new product in Magento, so when new product gets added, the email will be send to the admin containing all the values (Name, Model, SKU etc...)
straker1Asked:
Who is Participating?

[Webinar] Streamline your web hosting managementRegister Today

x
 
miked2004Connect With a Mentor Commented:
Not exactly sure what you mean.

Are you sending an email to the admin when a Backend user adds a new product?

If so create a custom module and add an observer for the "catalog_product_prepare_save" event.

This event will have the $product var passed in. You can access all the products attributes/information from this object. See code for example of retrieving attributes.

Here is a link on using observers: http://www.magentocommerce.com/wiki/customizing_magento_using_event-observer_method
$product->getSku();
$product->getPrice();
$product->getDescription();

Open in new window

0
All Courses

From novice to tech pro — start learning today.