AbanteCart Community

AbanteCart Development => Customization help => Topic started by: ambhar on July 03, 2014, 12:31:50 AM

Title: How To perform custom action on "Continue " button in Guest_step_2
Post by: ambhar on July 03, 2014, 12:31:50 AM
Hello....
              I have created a custom radio button for a payment option with default COD on guest_step_2. Whwn I check any of the payment option, it redirect me to the same page on which cash on delivery is redirected i.e. guest_step_3. I want to take the value of my radio button and perform my action for the payment for which I also need the session parameters about the transaction. How can I perform this??

Thanks in Advance
Waiting for a reply
Title: Re: How To perform custom action on "Continue " button in Guest_step_2
Post by: yonghan on July 03, 2014, 01:27:46 AM
Hi,have you looked at the controller that handle the action?
Title: Re: How To perform custom action on "Continue " button in Guest_step_2
Post by: ambhar on July 03, 2014, 02:48:34 AM
<button class="btn btn-orange pull-right ml10" title="<?php echo $form['continue']->name ?>" type="submit">
   <i class="icon-arrow-right icon-white"></i>
   <?php echo $form['continue']->name ?>
</button>
The above is the code for the button which I found after some hard work. And I am new to AbanteCart...have no idea about the code flow in it. Where can I find controller for this?
Title: Re: How To perform custom action on "Continue " button in Guest_step_2
Post by: yonghan on July 03, 2014, 09:29:10 AM
Hi,abantecary uses mvc.you can read the docs here : http://www.abantecart.com/document_wiki/index.php/Main_Page (http://www.abantecart.com/document_wiki/index.php/Main_Page)
Which tpl file did you edit?you can find the approtiate controller in
storefront/controller folder.Hope it helps.
Title: Re: How To perform custom action on "Continue " button in Guest_step_2
Post by: ambhar on July 04, 2014, 07:47:35 AM
Yonghan.........Thanks for your above reply. If I want to add a custom php page in place of success.tpl where I want to get some variables after the successful transaction and show them. How can I do this task in AbanteCart?
Title: Re: How To perform custom action on "Continue " button in Guest_step_2
Post by: yonghan on July 05, 2014, 04:32:16 AM
I think there are two ways if you want to add additional data to the tpl file.1st is directly edit the controller file to include data to the array,but the drawback is that when you update the abantecart,the file will be replaced.2nd is you create extension and hook the controller as described in the documentation too.please read the hook section.hope it helps. :)