Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Change Continue Shopping Path


BigMike7801

Recommended Posts

I would like when somebody presses the Continue Shopping button for it to take them back to the home page which is not an osCommerce page. I've targeted what I believe the code to be changed is which is:

 

<?php
$back = sizeof($navigation->path)-2;
if (isset($navigation->path[$back])) {
?>
			<td class="main"><?php echo '<a href="' . tep_href_link($navigation->path[$back]['page'], tep_array_to_string($navigation->path[$back]['get'], array('action')), $navigation->path[$back]['mode']) . '">' . tep_image_button('button_continue_shopping.gif', IMAGE_BUTTON_CONTINUE_SHOPPING) . '</a>'; ?></td>
<?php
}
?>

 

I know I can change the -2 to a -3 to make the number of pages it goes back different and stuff but I just want it to go to http://habfgiftshop.com

 

Any help would be appreciated

 

Thanks - Big Mike

Link to comment
Share on other sites

If you do not pass/store the session somewhere the shopping cart would be invalidated by doing this, since you redirect outside osc.

 

To add a page to the navigation class you have to create a function similar to add_current_page() and pass an argument to the script with any parameters needed. The function should store the script's name to the 'page' array element. So if the page with the parameters is not already stored you create a new entry in the storage array like this:

 

$this->path[] = array('page' => basename($PHP_SELF),
						  'mode' => $request_type,
						  'get' => $HTTP_GET_VARS,
						  'post' => $HTTP_POST_VARS);

Link to comment
Share on other sites

If you do not pass/store the session somewhere the shopping cart would be invalidated by doing this, since you redirect outside osc.

 

To add a page to the navigation class you have to create a function similar to add_current_page() and pass an argument to the script with any parameters needed. The function should store the script's name to the 'page' array element. So if the page with the parameters is not already stored you create a new entry in the storage array like this:

 

$this->path[] = array('page' => basename($PHP_SELF),
						  'mode' => $request_type,
						  'get' => $HTTP_GET_VARS,
						  'post' => $HTTP_POST_VARS);

 

So where would I put this code? Would it be in shopping_cart.php? If so what section? I'm not quite sure I understand. Because currently they can still nevigate the rest of the site and all is still remembered in the shopping cart.

Link to comment
Share on other sites

Archived

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

×
×
  • Create New...