- Posts: 10
- Thank you received: 1
Back button in checkout wont go back!
- lapartera69
-
Topic Author
- Offline
Less
More
13 years 9 months ago - 13 years 9 months ago #82888
by lapartera69
Back button in checkout wont go back! was created by lapartera69
Hi all
Just wondering if someone can help me out!
Added code for a back button in checkout but cant get it to go back to the last step, instead it moves forward. I haven't done a lot of coding in php and have read previous posts but still cant seem to work it out. This is what I have...
Any help would be greatly appreciated
Thanks
Just wondering if someone can help me out!
Added code for a back button in checkout but cant get it to go back to the last step, instead it moves forward. I haven't done a lot of coding in php and have read previous posts but still cant seem to work it out. This is what I have...
Code:
<?php
if($this->nextButton){
echo $this->cart->displayButton(JText::_('HIKA_NEXT'),'next',$this->params,hikashop_completeLink('checkout&task=step&step='.($this->step+1)),'if(hikashopCheckChangeForm(\'order\',\'hikashop_checkout_form\')){ if(hikashopCheckMethods()){ document.getElementById(\'hikashop_validate\').value=1; document.forms[\'hikashop_checkout_form\'].submit();}} return false;','id="hikashop_checkout_next_button"');
echo $this->cart->displayButton(JText::_('HIKA_BACK'),'next',$this->params,hikashop_completeLink('checkout&task=step&step='.($this->step-1)),'','id="hikashop_checkout_previous_button"');
}
?>
Any help would be greatly appreciated
Thanks
Last edit: 13 years 9 months ago by lapartera69.
Please Log in or Create an account to join the conversation.
13 years 9 months ago #82912
by Xavier
Replied by Xavier on topic Back button in checkout wont go back!
Hi,
After trying that code, it doesn't work.
You should try:
After trying that code, it doesn't work.
You should try:
Code:
<input onclick="location.href='<?php $stepb = $this->step-1; echo hikashop_completeLink('checkout&task=step&step='.$stepb.$url_itemid);?>'" type="button" name="Back" value="<?php echo JText::_('HIKA_BACK'); ?>" class="btn button hikashop_cart_input_button" id="hikashop_checkout_previous_button"; />
Please Log in or Create an account to join the conversation.
- lapartera69
-
Topic Author
- Offline
Less
More
- Posts: 10
- Thank you received: 1
13 years 9 months ago #82930
by lapartera69
Replied by lapartera69 on topic Back button in checkout wont go back!
Thanks so much Xavier! It worked a treat
Please Log in or Create an account to join the conversation.
Time to create page: 0.174 seconds