NoddyAsh Posted October 12, 2008 Posted October 12, 2008 (edited) Hi, I must have set something wrong here. If a customer starts the purchase process but doesn't make final payment (order Status Preparing IPN) the download link IS visible under their account details. Help appreciated, thanks. Russ Edited October 12, 2008 by NoddyAsh Quote
web-project Posted October 12, 2008 Posted October 12, 2008 with download products, you need to modify the checkout process to disable the downloads if the payment not confirmed by IPN. Quote Please read this line: Do you want to find all the answers to your questions? click here. As for contribution database it's located here! 8 people out of 10 don't bother to read installation manuals. I can recommend: if you can't read the installation manual, don't bother to install any contribution yourself. Before installing contribution or editing/updating/deleting any files, do the full backup, it will save to you & everyone here on the forum time to fix your issues. Any issues with oscommerce, I am here to help you.
NoddyAsh Posted October 12, 2008 Author Posted October 12, 2008 with download products, you need to modify the checkout process to disable the downloads if the payment not confirmed by IPN. Could you advise how this can be done, thanks. Russ Quote
web-project Posted October 13, 2008 Posted October 13, 2008 open the following file: account_history.php find the code: <?php if (DOWNLOAD_ENABLED == 'true') include(DIR_WS_MODULES . 'downloads.php'); ?> replace with: <?php //check the order status from db $check_status_order_query = tep_db_query("select os.orders_status_name, osh.date_added, osh.comments from " . TABLE_ORDERS_STATUS . " os, " . TABLE_ORDERS_STATUS_HISTORY . " osh where osh.orders_id = '" . (int)$HTTP_GET_VARS['order_id'] . "' and osh.orders_status_id = os.orders_status_id and os.language_id = '" . (int)$languages_id . "' and os.public_flag = '1' order by osh.date_added DESC LIMIT 0 , 1"); $status = tep_db_fetch_array($check_status_order_query); //if the status is Preparing [PayPal IPN] or Paid [PayPal IPN] allow to customer to access the digital content if($status['orders_status_name']=="Preparing [PayPal IPN]"){ if (DOWNLOAD_ENABLED == 'true') include(DIR_WS_MODULES . 'downloads.php'); } ?> Quote Please read this line: Do you want to find all the answers to your questions? click here. As for contribution database it's located here! 8 people out of 10 don't bother to read installation manuals. I can recommend: if you can't read the installation manual, don't bother to install any contribution yourself. Before installing contribution or editing/updating/deleting any files, do the full backup, it will save to you & everyone here on the forum time to fix your issues. Any issues with oscommerce, I am here to help you.
NoddyAsh Posted October 14, 2008 Author Posted October 14, 2008 open the following file:account_history.php find the code: <?php if (DOWNLOAD_ENABLED == 'true') include(DIR_WS_MODULES . 'downloads.php'); ?> replace with: <?php //check the order status from db $check_status_order_query = tep_db_query("select os.orders_status_name, osh.date_added, osh.comments from " . TABLE_ORDERS_STATUS . " os, " . TABLE_ORDERS_STATUS_HISTORY . " osh where osh.orders_id = '" . (int)$HTTP_GET_VARS['order_id'] . "' and osh.orders_status_id = os.orders_status_id and os.language_id = '" . (int)$languages_id . "' and os.public_flag = '1' order by osh.date_added DESC LIMIT 0 , 1"); $status = tep_db_fetch_array($check_status_order_query); //if the status is Preparing [PayPal IPN] or Paid [PayPal IPN] allow to customer to access the digital content if($status['orders_status_name']=="Preparing [PayPal IPN]"){ if (DOWNLOAD_ENABLED == 'true') include(DIR_WS_MODULES . 'downloads.php'); } ?> Many thanks, will give it a go. Looking at the code though it would appear to still show the link if status preparing. Let's try it first though. Russ Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.