I was unable to display the payment form for "My Custom Gateway" when the method is selected.
I have created the
form.phtml template and it is loaded correctly. I can see the tag is loaded properly. Moreover it is visible even when I have not choose that method yet. Thus I have to hide the form until the the gateway is selected, so I have the following
<?php // PHP Code ?> <ul class="form-list" id="mygateway_form_<?php echo $this->getMethodCode() ?>" style="display:none;"> <li> <div class="input-box"> This will be the Forms </div> </li> </ul>
In my Model, I'm extending
Mage_Payment_Model_Method_Abstract instead of
I couldn't find any reference in the Magento source code that take care this trivial logic: hiding and showing payment form.
So, in magento, how to make my payment form visible when the user click on that particular payment methods?