Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

back button with previous position


VALENC1ANO

Recommended Posts

Posted

In my product listing when i click BUY NOW the quantity adds to my cart without problems. But at this time the page refresh and returns to the top of the page.

 

The problem is when my customer is at the botton of the page, because when click BUY NOW the refresh returns my customer to the top and he needs to down with the scroll until he looks for the product that he was add in the last click.

 

I need when the page refresh on click BUY NOW it keeps the position on the last product.

 

The code where appears this is the next:

 

<?php

 

echo '<form name="cart_quantity" method="post" action="' . tep_href_link(basename($PHP_SELF), tep_get_all_get_params(array('action')) . 'action=add_product', 'NONSSL'). '"><input type="hidden" name="products_id" value="' . $products_outlet['products_id'] . '"><input type="text" name="quantity" align="center" value="1" maxlength="5" size="2"><br>' . tep_image_submit('button_buy_now.gif', IMAGE_BUTTON_BUY_NOW) . '</form>'

 

?>

 

The code i think i need to modify is basename($PHP_SELF) but i don't know which is the rigth form.

 

Anybody could help me?

 

sorry for my english :(

 

thanks

Posted

Try admin>configuration>display cart after adding product

set this to true, I think this might be what you are trying to achieve, when customer clicks continue shopping they will go back to original product.

Posted

Hi Brian,

 

Thank you for your answer but it isn't a good solution for me. I need to keep in product listing without pass for the cart.

 

In any case very thanks for your help.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...