snubbr.com

Can a "web site" on Windows 2003 Server have multiple Verisign SSL ceritificates for different domai

Get a Verisign SSL certificate for 30 days FREE. Click here to use coupon...

Get a free trial of Verisign SSL certificates. Click here for this special deal...
Got a quick question: Can a "web site" on Windows 2003 Server have multiple Verisign SSL ceritificates for different domai Many thanks for any response. Second question of mine... Hi everyone,.

Quick simple question for you. maybe!.

How do I redirect people to the account page on clicking continue button on the checkout success page. WHat link would it have to be..

At the moment it redirects them to index..

Any ideas?..

Comments (158)

Yep, however you might wanna make sure and wait for another member here to confirm this as I am unsure of myself. Better yet, why don't you call the Verisign guys because they can give you an answer better...

Comment #1

I don't think that it would be good if you have purchase without account...

Comment #2

I only answered the "how"..

Now the "why?" and "is it a good idea?".

Well... I don't know!..

Comment #3

'I don't think that it would be good if you have purchase without account. '.

Yeah your right....didnt think of that one. is there any way then that if the customer is logged in then the logoff button is displayed on checkout success..

Hey, thanks for quick replys..

Comment #4

Just thought thou, if the PWA member was to be directed to the account page it would be detected that they needed to login and redirect again there..

Does that make sense?..

Comment #5

You could try it, but it may be confusing for them..

It would be better if they were directed to the default and an account holder directed to their account..

This post has been edited by.

Coopco.

: 19 January 2009, 01:10..

Comment #6

How could I achieve this? This sounds perfect but how? I take it's the coding on the continue button on the checkout success page. saying something like if customer is registered direct there else if customer is PWA do to default. (obviously dont know where to start with the code).

Any ideas? You guys seem pro's in php, or at least have better knowledge than me..

Regards,.

Really appreciate your replies...

Comment #7

If your using PWA (Purchase Without Account) then you should already have this in.

Checkout_success.php.

:.

// PWA BOF.

If($customer_id != 0).

{.

Tep_redirect(tep_href_link(FILENAME_DEFAULT, $notify_string));.

}.

Else.

{.

Tep_session_unregister('pwa_array_customer');.

Tep_session_unregister('pwa_array_address');.

Tep_session_unregister('pwa_array_shipping');.

Tep_session_unregister('customer_id');.

Tep_redirect(tep_href_link(FILENAME_DEFAULT));.

}.

// PWA EOF.

Simply change it to:.

// PWA BOF.

If($customer_id != 0).

{.

Tep_redirect(tep_href_link(FILENAME_ACCOUNT, $notify_string));.

}.

Else.

{.

Tep_session_unregister('pwa_array_customer');.

Tep_session_unregister('pwa_array_address');.

Tep_session_unregister('pwa_array_shipping');.

Tep_session_unregister('customer_id');.

Tep_redirect(tep_href_link(FILENAME_DEFAULT));.

}.

// PWA EOF..

Comment #8

This sounds great but dont have the above what I have is:.

"<?php.

/*.

$Id: checkout_success.php 1749 2007-12-21 04:23:36Z hpdl $.

OsCommerce, Open Source E-Commerce Solutions.

Http://www.oscommerce.com.

Copyright © 2007 osCommerce.

Released under the GNU General Public License.

*/.

Require('includes/application_top.php');.

// if the customer is not logged on, redirect them to the shopping cart page.

If (!tep_session_is_registered('customer_id')) {.

Tep_redirect(tep_href_link(FILENAME_SHOPPING_CART));.

}.

If (isset($HTTP_GET_VARS['action']) && ($HTTP_GET_VARS['action'] == 'update')) {.

$notify_string = '';.

If (isset($HTTP_POST_VARS['notify']) && !empty($HTTP_POST_VARS['notify'])) {.

$notify = $HTTP_POST_VARS['notify'];.

If (!is_array($notify)) {.

$notify = array($notify);.

}.

For ($i=0, $n=sizeof($notify); $i<$n; $i++) {.

If (is_numeric($notify[$i])) {.

$notify_string .= 'notify[]='$notify[$i]'&';.

}.

}.

If (!empty($notify_string)) {.

$notify_string = 'action=notify&'substr($notify_string, 0, -1);.

}.

}.

Tep_redirect(tep_href_link(FILENAME_DEFAULT, $notify_string));.

}.

Require(DIR_WS_LANGUAGES$language'/'FILENAME_CHECKOUT_SUCCESS);.

Can I simply replace the bit in bold? to what you put..

Comment #9

Are you sure your using PWA? And if so which version are you using? And did you install it correctly?? Because what I posted in my previous post is mandatory to be placed in the checkout_success.php page if you've installed PWA because it unregisters the "guest" session once checkout has been completed (if they checked out without creating an account)..

Comment #10

Hi I double checked it an no there aint no code like that posted the code so you can see what it does state. Its PWA version 2.0h and strange thing is it does unregister the guest as checked it's doing that in the admin screen and it's working fine. I may just leave it just in case it breaks it..

<?php.

/*.

$Id: checkout_success.php 1749 2007-12-21 04:23:36Z hpdl $.

OsCommerce, Open Source E-Commerce Solutions.

Http://www.oscommerce.com.

Copyright (c) 2007 osCommerce.

Released under the GNU General Public License.

*/.

Require('includes/application_top.php');.

// if the customer is not logged on, redirect them to the shopping cart page.

If (!tep_session_is_registered('customer_id')) {.

Tep_redirect(tep_href_link(FILENAME_SHOPPING_CART));.

}.

If (isset($HTTP_GET_VARS['action']) && ($HTTP_GET_VARS['action'] == 'update')) {.

$notify_string = '';.

If (isset($HTTP_POST_VARS['notify']) && !empty($HTTP_POST_VARS['notify'])) {.

$notify = $HTTP_POST_VARS['notify'];.

If (!is_array($notify)) {.

$notify = array($notify);.

}.

For ($i=0, $n=sizeof($notify); $i<$n; $i++) {.

If (is_numeric($notify[$i])) {.

$notify_string .= 'notify[]='$notify[$i]'&';.

}.

}.

If (!empty($notify_string)) {.

$notify_string = 'action=notify&'substr($notify_string, 0, -1);.

}.

}.

Tep_redirect(tep_href_link(FILENAME_DEFAULT, $notify_string));.

}.

Require(DIR_WS_LANGUAGES$language'/'FILENAME_CHECKOUT_SUCCESS);.

$breadcrumb->add(NAVBAR_TITLE_1);.

$breadcrumb->add(NAVBAR_TITLE_2);.

$global_query = tep_db_query("select global_product_notifications from "TABLE_CUSTOMERS_INFO" where customers_info_id = '"(int)$customer_id"'");.

$global = tep_db_fetch_array($global_query);.

If ($global['global_product_notifications'] != '1') {.

$orders_query = tep_db_query("select orders_id from "TABLE_ORDERS" where customers_id = '"(int)$customer_id"' order by date_purchased desc limit 1");.

$orders = tep_db_fetch_array($orders_query);.

$products_array = array();.

$products_query = tep_db_query("select products_id, products_name from "TABLE_ORDERS_PRODUCTS" where orders_id = '"(int)$orders['orders_id']"' order by products_name");.

While ($products = tep_db_fetch_array($products_query)) {.

$products_array[] = array('id' => $products['products_id'],.

'text' => $products['products_name']);.

}.

}.

?>.

<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">.

<html <?php echo HTML_PARAMS; ?>>.

<head>.

<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">.

<title><?php echo TITLE; ?></title>.

<base href="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER)DIR_WS_CATALOG; ?>">.

<link rel="stylesheet" type="text/css" href="stylesheet.css">.

</head>.

<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0">.

<! header //>.

<?php require(DIR_WS_INCLUDES'header.php'); ?>.

<! header_eof //>.

<! body //>.

<table border="0" width="100%" cellspacing="3" cellpadding="3">.

<tr>.

<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">.

<! left_navigation //>.

<?php require(DIR_WS_INCLUDES'column_left.php'); ?>.

<! left_navigation_eof //>.

</table></td>.

<! body_text //>.

<td width="100%" valign="top"><?php echo tep_draw_form('order', tep_href_link(FILENAME_CHECKOUT_SUCCESS, 'action=update', 'SSL')); ?><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td><table border="0" width="100%" cellspacing="4" cellpadding="2">.

<tr>.

<td valign="top"><?php echo tep_image(DIR_WS_IMAGES'table_background_man_on_board.gif', HEADING_TITLE); ?></td>.

<td valign="top" class="main"><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?><div align="center" class="pageHeading"><?php echo HEADING_TITLE; ?></div><br><?php echo TEXT_SUCCESS; ?><br><br>.

<?php.

//PWA BOF.

If (!tep_session_is_registered('customer_is_guest')){.

//PWA BOF.

If ($global['global_product_notifications'] != '1') {.

Echo TEXT_NOTIFY_PRODUCTS'<br><p class="productsNotifications">';.

$products_displayed = array();.

For ($i=0, $n=sizeof($products_array); $i<$n; $i++) {.

If (!in_array($products_array[$i]['id'], $products_displayed)) {.

Echo tep_draw_checkbox_field('notify[]', $products_array[$i]['id'])' '$products_array[$i]['text']'<br>';.

$products_displayed[] = $products_array[$i]['id'];.

}.

}.

Echo '</p>';.

} else {.

Echo TEXT_SEE_ORDERS'<br><br>'TEXT_CONTACT_STORE_OWNER;.

}.

//PWA BOF.

}.

//PWA BOF.

?>.

<h3><?php echo TEXT_THANKS_FOR_SHOPPING; ?></h3></td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>.

</tr>.

<tr>.

<td align="right" class="main"><?php echo tep_image_submit('button_continue.gif', IMAGE_BUTTON_CONTINUE); ?></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>.

</tr>.

<tr>.

<td><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td width="25%"><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td width="50%" align="right"><?php echo tep_draw_separator('pixel_silver.gif', '1', '5'); ?></td>.

<td width="50%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

</tr>.

</table></td>.

<td width="25%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

<td width="25%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

<td width="25%"><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td width="50%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

<td width="50%"><?php echo tep_image(DIR_WS_IMAGES'checkout_bullet.gif'); ?></td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td align="center" width="25%" class="checkoutBarFrom"><?php echo CHECKOUT_BAR_DELIVERY; ?></td>.

<td align="center" width="25%" class="checkoutBarFrom"><?php echo CHECKOUT_BAR_PAYMENT; ?></td>.

<td align="center" width="25%" class="checkoutBarFrom"><?php echo CHECKOUT_BAR_CONFIRMATION; ?></td>.

<td align="center" width="25%" class="checkoutBarCurrent"><?php echo CHECKOUT_BAR_FINISHED; ?></td>.

</tr>.

</table></td>.

</tr>.

<?php if (DOWNLOAD_ENABLED == 'true') include(DIR_WS_MODULES'downloads.php'); ?>.

</table></form></td>.

<! body_text_eof //>.

<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">.

<! right_navigation //>.

<?php require(DIR_WS_INCLUDES'column_right.php'); ?>.

<! right_navigation_eof //>.

</table></td>.

</tr>.

</table>.

<! body_eof //>.

<! footer //>.

<?php require(DIR_WS_INCLUDES'footer.php'); ?>.

<! footer_eof //>.

<br>.

</body>.

</html>.

<?php require(DIR_WS_INCLUDES'application_bottom.php'); ?>..

Comment #11

Try this and see if it works -.

PLEASE BACKUP checkout_success.php FIRST BEFORE CHANGING IT TO THIS.

<?php.

/*.

$Id: checkout_success.php 1749 2007-12-21 04:23:36Z hpdl $.

OsCommerce, Open Source E-Commerce Solutions.

Http://www.oscommerce.com.

Copyright (c) 2007 osCommerce.

Released under the GNU General Public License.

*/.

Require('includes/application_top.php');.

// if the customer is not logged on, redirect them to the shopping cart page.

If (!tep_session_is_registered('customer_id')) {.

Tep_redirect(tep_href_link(FILENAME_SHOPPING_CART));.

}.

If (isset($HTTP_GET_VARS['action']) && ($HTTP_GET_VARS['action'] == 'update')) {.

$notify_string = '';.

If (isset($HTTP_POST_VARS['notify']) && !empty($HTTP_POST_VARS['notify'])) {.

$notify = $HTTP_POST_VARS['notify'];.

If (!is_array($notify)) {.

$notify = array($notify);.

}.

For ($i=0, $n=sizeof($notify); $i<$n; $i++) {.

If (is_numeric($notify[$i])) {.

$notify_string .= 'notify[]='$notify[$i]'&';.

}.

}.

If (!empty($notify_string)) {.

$notify_string = 'action=notify&'substr($notify_string, 0, -1);.

}.

}.

If($customer_id != 0).

{.

Tep_redirect(tep_href_link(FILENAME_ACCOUNT, $notify_string));.

}.

Else.

{.

Tep_redirect(tep_href_link(FILENAME_DEFAULT, $notify_string));.

}.

}.

Require(DIR_WS_LANGUAGES$language'/'FILENAME_CHECKOUT_SUCCESS);.

$breadcrumb->add(NAVBAR_TITLE_1);.

$breadcrumb->add(NAVBAR_TITLE_2);.

$global_query = tep_db_query("select global_product_notifications from "TABLE_CUSTOMERS_INFO" where customers_info_id = '"(int)$customer_id"'");.

$global = tep_db_fetch_array($global_query);.

If ($global['global_product_notifications'] != '1') {.

$orders_query = tep_db_query("select orders_id from "TABLE_ORDERS" where customers_id = '"(int)$customer_id"' order by date_purchased desc limit 1");.

$orders = tep_db_fetch_array($orders_query);.

$products_array = array();.

$products_query = tep_db_query("select products_id, products_name from "TABLE_ORDERS_PRODUCTS" where orders_id = '"(int)$orders['orders_id']"' order by products_name");.

While ($products = tep_db_fetch_array($products_query)) {.

$products_array[] = array('id' => $products['products_id'],.

'text' => $products['products_name']);.

}.

}.

?>.

<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">.

<html <?php echo HTML_PARAMS; ?>>.

<head>.

<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">.

<title><?php echo TITLE; ?></title>.

<base href="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER)DIR_WS_CATALOG; ?>">.

<link rel="stylesheet" type="text/css" href="stylesheet.css">.

</head>.

<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0">.

<! header //>.

<?php require(DIR_WS_INCLUDES'header.php'); ?>.

<! header_eof //>.

<! body //>.

<table border="0" width="100%" cellspacing="3" cellpadding="3">.

<tr>.

<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">.

<! left_navigation //>.

<?php require(DIR_WS_INCLUDES'column_left.php'); ?>.

<! left_navigation_eof //>.

</table></td>.

<! body_text //>.

<td width="100%" valign="top"><?php echo tep_draw_form('order', tep_href_link(FILENAME_CHECKOUT_SUCCESS, 'action=update', 'SSL')); ?><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td><table border="0" width="100%" cellspacing="4" cellpadding="2">.

<tr>.

<td valign="top"><?php echo tep_image(DIR_WS_IMAGES'table_background_man_on_board.gif', HEADING_TITLE); ?></td>.

<td valign="top" class="main"><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?><div align="center" class="pageHeading"><?php echo HEADING_TITLE; ?></div><br><?php echo TEXT_SUCCESS; ?><br><br>.

<?php.

//PWA BOF.

If (!tep_session_is_registered('customer_is_guest')){.

//PWA BOF.

If ($global['global_product_notifications'] != '1') {.

Echo TEXT_NOTIFY_PRODUCTS'<br><p class="productsNotifications">';.

$products_displayed = array();.

For ($i=0, $n=sizeof($products_array); $i<$n; $i++) {.

If (!in_array($products_array[$i]['id'], $products_displayed)) {.

Echo tep_draw_checkbox_field('notify[]', $products_array[$i]['id'])' '$products_array[$i]['text']'<br>';.

$products_displayed[] = $products_array[$i]['id'];.

}.

}.

Echo '</p>';.

} else {.

Echo TEXT_SEE_ORDERS'<br><br>'TEXT_CONTACT_STORE_OWNER;.

}.

//PWA BOF.

}.

//PWA BOF.

?>.

<h3><?php echo TEXT_THANKS_FOR_SHOPPING; ?></h3></td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>.

</tr>.

<tr>.

<td align="right" class="main"><?php echo tep_image_submit('button_continue.gif', IMAGE_BUTTON_CONTINUE); ?></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>.

</tr>.

<tr>.

<td><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td width="25%"><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td width="50%" align="right"><?php echo tep_draw_separator('pixel_silver.gif', '1', '5'); ?></td>.

<td width="50%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

</tr>.

</table></td>.

<td width="25%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

<td width="25%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

<td width="25%"><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td width="50%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

<td width="50%"><?php echo tep_image(DIR_WS_IMAGES'checkout_bullet.gif'); ?></td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td align="center" width="25%" class="checkoutBarFrom"><?php echo CHECKOUT_BAR_DELIVERY; ?></td>.

<td align="center" width="25%" class="checkoutBarFrom"><?php echo CHECKOUT_BAR_PAYMENT; ?></td>.

<td align="center" width="25%" class="checkoutBarFrom"><?php echo CHECKOUT_BAR_CONFIRMATION; ?></td>.

<td align="center" width="25%" class="checkoutBarCurrent"><?php echo CHECKOUT_BAR_FINISHED; ?></td>.

</tr>.

</table></td>.

</tr>.

<?php if (DOWNLOAD_ENABLED == 'true') include(DIR_WS_MODULES'downloads.php'); ?>.

</table></form></td>.

<! body_text_eof //>.

<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">.

<! right_navigation //>.

<?php require(DIR_WS_INCLUDES'column_right.php'); ?>.

<! right_navigation_eof //>.

</table></td>.

</tr>.

</table>.

<! body_eof //>.

<! footer //>.

<?php require(DIR_WS_INCLUDES'footer.php'); ?>.

<! footer_eof //>.

<br>.

</body>.

</html>.

<?php require(DIR_WS_INCLUDES'application_bottom.php'); ?>.

Try checking out with both an account created and no account created ... it should (hopefully) redirect to My Account (if there was an account) or redirect to main page (if checked out without account)..

Comment #12

Try checking out with both an account created and no account created ... it should (hopefully) redirect to My Account (if there was an account) or redirect to main page (if checked out without account).

[/quote].

Cool I shall try the code you stated and see if works, not forgetting to backup..

I have found another problem you may be able to help me with (lost the capability to copy /duplicate an item in admin (catalog) and would be very handy if I could get this function back. I have started a new post not to confuse...

Comment #13

Your a star it seems to be working perfect. one question. I have sessions registered. should i. coz when I tried with PWA and tested and then added another product this was after checkout complete it saved my details of address etc... to me I think that is what sessions do aint it but not sure?.

If this is correct then your a star and your code is doing as it should..

Very very happy indeed..

10/10 for you...

Comment #14

That's what I was worried about before ... the guest account sessions in your checkout_success.php arent clearing once checkout is complete ... it should definately remove it after checkout (please note I'm talking about GUEST (no account) sessions here - if your checking out with an account and you mean the address is still there this is what it's meant to do - it's only meant to clear the sessions however for the guest account that your customer uses) - Here try this one which will unregister the guest sessions after checkout has completed.

Once again backup checkout_success.php first!!.

<?php.

/*.

$Id: checkout_success.php 1749 2007-12-21 04:23:36Z hpdl $.

OsCommerce, Open Source E-Commerce Solutions.

Http://www.oscommerce.com.

Copyright (c) 2007 osCommerce.

Released under the GNU General Public License.

*/.

Require('includes/application_top.php');.

// if the customer is not logged on, redirect them to the shopping cart page.

If (!tep_session_is_registered('customer_id')) {.

Tep_redirect(tep_href_link(FILENAME_SHOPPING_CART));.

}.

If (isset($HTTP_GET_VARS['action']) && ($HTTP_GET_VARS['action'] == 'update')) {.

$notify_string = '';.

If (isset($HTTP_POST_VARS['notify']) && !empty($HTTP_POST_VARS['notify'])) {.

$notify = $HTTP_POST_VARS['notify'];.

If (!is_array($notify)) {.

$notify = array($notify);.

}.

For ($i=0, $n=sizeof($notify); $i<$n; $i++) {.

If (is_numeric($notify[$i])) {.

$notify_string .= 'notify[]='$notify[$i]'&';.

}.

}.

If (!empty($notify_string)) {.

$notify_string = 'action=notify&'substr($notify_string, 0, -1);.

}.

}.

// PWA BOF.

If($customer_id != 0).

{.

Tep_redirect(tep_href_link(FILENAME_ACCOUNT, $notify_string));.

}.

Else.

{.

Tep_session_unregister('pwa_array_customer');.

Tep_session_unregister('pwa_array_address');.

Tep_session_unregister('pwa_array_shipping');.

Tep_session_unregister('customer_id');.

Tep_redirect(tep_href_link(FILENAME_DEFAULT));.

}.

// PWA EOF.

}.

Require(DIR_WS_LANGUAGES$language'/'FILENAME_CHECKOUT_SUCCESS);.

$breadcrumb->add(NAVBAR_TITLE_1);.

$breadcrumb->add(NAVBAR_TITLE_2);.

$global_query = tep_db_query("select global_product_notifications from "TABLE_CUSTOMERS_INFO" where customers_info_id = '"(int)$customer_id"'");.

$global = tep_db_fetch_array($global_query);.

If ($global['global_product_notifications'] != '1') {.

$orders_query = tep_db_query("select orders_id from "TABLE_ORDERS" where customers_id = '"(int)$customer_id"' order by date_purchased desc limit 1");.

$orders = tep_db_fetch_array($orders_query);.

$products_array = array();.

$products_query = tep_db_query("select products_id, products_name from "TABLE_ORDERS_PRODUCTS" where orders_id = '"(int)$orders['orders_id']"' order by products_name");.

While ($products = tep_db_fetch_array($products_query)) {.

$products_array[] = array('id' => $products['products_id'],.

'text' => $products['products_name']);.

}.

}.

?>.

<!doctype html public "-//W3C//DTD HTML 4.01 Transitional//EN">.

<html <?php echo HTML_PARAMS; ?>>.

<head>.

<meta http-equiv="Content-Type" content="text/html; charset=<?php echo CHARSET; ?>">.

<title><?php echo TITLE; ?></title>.

<base href="<?php echo (($request_type == 'SSL') ? HTTPS_SERVER : HTTP_SERVER)DIR_WS_CATALOG; ?>">.

<link rel="stylesheet" type="text/css" href="stylesheet.css">.

</head>.

<body marginwidth="0" marginheight="0" topmargin="0" bottommargin="0" leftmargin="0" rightmargin="0">.

<! header //>.

<?php require(DIR_WS_INCLUDES'header.php'); ?>.

<! header_eof //>.

<! body //>.

<table border="0" width="100%" cellspacing="3" cellpadding="3">.

<tr>.

<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">.

<! left_navigation //>.

<?php require(DIR_WS_INCLUDES'column_left.php'); ?>.

<! left_navigation_eof //>.

</table></td>.

<! body_text //>.

<td width="100%" valign="top"><?php echo tep_draw_form('order', tep_href_link(FILENAME_CHECKOUT_SUCCESS, 'action=update', 'SSL')); ?><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td><table border="0" width="100%" cellspacing="4" cellpadding="2">.

<tr>.

<td valign="top"><?php echo tep_image(DIR_WS_IMAGES'table_background_man_on_board.gif', HEADING_TITLE); ?></td>.

<td valign="top" class="main"><?php echo tep_draw_separator('pixel_trans.gif', '1', '10'); ?><div align="center" class="pageHeading"><?php echo HEADING_TITLE; ?></div><br><?php echo TEXT_SUCCESS; ?><br><br>.

<?php.

//PWA BOF.

If (!tep_session_is_registered('customer_is_guest')){.

//PWA BOF.

If ($global['global_product_notifications'] != '1') {.

Echo TEXT_NOTIFY_PRODUCTS'<br><p class="productsNotifications">';.

$products_displayed = array();.

For ($i=0, $n=sizeof($products_array); $i<$n; $i++) {.

If (!in_array($products_array[$i]['id'], $products_displayed)) {.

Echo tep_draw_checkbox_field('notify[]', $products_array[$i]['id'])' '$products_array[$i]['text']'<br>';.

$products_displayed[] = $products_array[$i]['id'];.

}.

}.

Echo '</p>';.

} else {.

Echo TEXT_SEE_ORDERS'<br><br>'TEXT_CONTACT_STORE_OWNER;.

}.

//PWA BOF.

}.

//PWA BOF.

?>.

<h3><?php echo TEXT_THANKS_FOR_SHOPPING; ?></h3></td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>.

</tr>.

<tr>.

<td align="right" class="main"><?php echo tep_image_submit('button_continue.gif', IMAGE_BUTTON_CONTINUE); ?></td>.

</tr>.

<tr>.

<td><?php echo tep_draw_separator('pixel_trans.gif', '100%', '10'); ?></td>.

</tr>.

<tr>.

<td><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td width="25%"><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td width="50%" align="right"><?php echo tep_draw_separator('pixel_silver.gif', '1', '5'); ?></td>.

<td width="50%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

</tr>.

</table></td>.

<td width="25%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

<td width="25%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

<td width="25%"><table border="0" width="100%" cellspacing="0" cellpadding="0">.

<tr>.

<td width="50%"><?php echo tep_draw_separator('pixel_silver.gif', '100%', '1'); ?></td>.

<td width="50%"><?php echo tep_image(DIR_WS_IMAGES'checkout_bullet.gif'); ?></td>.

</tr>.

</table></td>.

</tr>.

<tr>.

<td align="center" width="25%" class="checkoutBarFrom"><?php echo CHECKOUT_BAR_DELIVERY; ?></td>.

<td align="center" width="25%" class="checkoutBarFrom"><?php echo CHECKOUT_BAR_PAYMENT; ?></td>.

<td align="center" width="25%" class="checkoutBarFrom"><?php echo CHECKOUT_BAR_CONFIRMATION; ?></td>.

<td align="center" width="25%" class="checkoutBarCurrent"><?php echo CHECKOUT_BAR_FINISHED; ?></td>.

</tr>.

</table></td>.

</tr>.

<?php if (DOWNLOAD_ENABLED == 'true') include(DIR_WS_MODULES'downloads.php'); ?>.

</table></form></td>.

<! body_text_eof //>.

<td width="<?php echo BOX_WIDTH; ?>" valign="top"><table border="0" width="<?php echo BOX_WIDTH; ?>" cellspacing="0" cellpadding="2">.

<! right_navigation //>.

<?php require(DIR_WS_INCLUDES'column_right.php'); ?>.

<! right_navigation_eof //>.

</table></td>.

</tr>.

</table>.

<! body_eof //>.

<! footer //>.

<?php require(DIR_WS_INCLUDES'footer.php'); ?>.

<! footer_eof //>.

<br>.

</body>.

</html>.

<?php require(DIR_WS_INCLUDES'application_bottom.php'); ?>..

Comment #15

Hi everyone,.

Quick simple question for you. maybe!.

How do I redirect people to the account page on clicking continue button on the checkout success page. WHat link would it have to be..

At the moment it redirects them to index..

Any ideas?..

Comment #16

Find this code at the top of the file (.

/catalog/.

Checkout_success.php.

):.

If (isset($HTTP_GET_VARS['action']) && ($HTTP_GET_VARS['action'] == 'update')) {.

$notify_string = 'action=notify&';.

$notify = $HTTP_POST_VARS['notify'];.

If (!is_array($notify)) $notify = array($notify);.

For ($i=0, $n=sizeof($notify); $i<$n; $i++) {.

$notify_string .= 'notify[]='$notify[$i]'&';.

}.

If (strlen($notify_string) > 0) $notify_string = substr($notify_string, 0, -1);.

Tep_redirect(tep_href_link(FILENAME_DEFAULT, $notify_string));.

}.

Change the next to last last line to:.

Tep_redirect(tep_href_link(FILENAME_ACCOUNT, $notify_string));.

Backup the file first!..

Comment #17


This question was taken from a support group/message board and re-posted here so others can learn from it.

 

Categories: Home | Diet & Weight Management | Vitamins & Supplements | Herbs & Cleansing |

Sexual Health | Medifast Support | Nutrisystem Support | Medifast Questions |

Web Hosting | Web Hosts | Website Hosting | Hosting |

Web Hosting | GoDaddy | Digital Cameras | Best WebHosts |

Web Hosting FAQ | Web Hosts FAQ | Hosting FAQ | Hosting Group |

Hosting Questions | Camera Tips | Best Cameras To Buy | Best Cameras This Year |

Camera Q-A | Digital Cameras Q-A | Camera Forum | Nov 2010 - Cameras |

Oct 2010 - Cameras | Oct 2010 - DSLRs | Oct 2010 - Camera Tips | Sep 2010 - Cameras |

Sep 2010 - DSLRS | Sep 2010 - Camera Tips | Aug 2010 - Cameras | Aug 2010 - DSLR Tips |

Aug 2010 - Camera Tips | July 2010 - Cameras | July 2010 - Nikon Cameras | July 2010 - Canon Cameras |

July 2010 - Pentax Cameras | Medifast Recipes | Medifast Recipes Tips | Medifast Recipes Strategies |

Medifast Recipes Experiences | Medifast Recipes Group | Medifast Recipes Forum | Medifast Support Strategies |

Medifast Support Experiences |

 

(C) Copyright 2010 All rights reserved.