1

I have just added a custom drop down option at the payment method section for users to select. Once the payment success, this extra custom option will be sent to the store's email along with all the other shipping/billing/etc information.

Which file do I edit now to allow this added custom field to be sent along with all the other fields? I just don't know how this all handled in the Magento system at the moment.

The code I just added in shipping_method.phtml:

<div class="occassion">
    <h4><?php echo $this->__('Special Occassion?'); ?></h4>
        <select>
            <option value="" selected>None</option>
            <option value="birthday">Birthday</option>
            <option value="valentines">Valentine's Day</option>
            <option value="holidays">Holidays</option>
            <option value="anniversary">Anniversary</option>
            <option value="graduation">Graduation</option>
        </select>
</div>
0

You can use observer(after order success [checkout_onepage_controller_success_action]) to track order and get the order payment status if payment status is success mail to user/admin with that extra custom option value.

There are below some events to capture order detail:

  • checkout_onepage_controller_success_action
  • sales_order_payment_capture
  • sales_order_invoice_pay

You can use one of above observer events.

Note: To learn observer in magento read link http://inchoo.net/magento/custom-magento-events-customer-first-order/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.