Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Sign in to follow this  
AlexStudio

Installation Guide - osC Paypal IPN 1.1 + Downloads Controller 5.3 - on fresh osC MS2.2

Recommended Posts

a few things:

 

1. papabruin is right - the sql file is not in either of the packages mentioned in the original post/tutorial. it must be acquired through the "Download / Free Ship /Pay v5.3 MS 2.2 Farrukh Saeed 7 Aug 2003" file.

 

2. i want my customers to be able to download the file right after they have completed the paypal checkout process. for this, i had to change the `set preparing orders status` to `11 downloads now available`. the download link was still not appearing after they were returned to checkout_success.php. the expiry date for downloads was messed up (showing 19 dec 1999 or some other date in 99). the was also not available under 'my account'.

 

this was happening because the `last_modified` field in the `orders` table was NULL, and that was being used to calculate the expiry date for downloads.

 

i changed catalog/includes/modules/download.php at line 29 to:

 

$downloads_query = tep_db_query("select o.orders_status, date_format(o.date_purchased, '%Y-%m-%d') as date_purchased_day, opd.download_maxdays, op.products_name, opd.orders_products_download_id, opd.orders_products_filename, opd.download_count, opd.download_maxdays from " . TABLE_ORDERS . " o, " . TABLE_ORDERS_PRODUCTS . " op, " . TABLE_ORDERS_PRODUCTS_DOWNLOAD . " opd where o.customers_id = '" . (int)$customer_id . "' and o.orders_status >= '" . DOWNLOADS_CONTROLLER_ORDERS_STATUS . "' and o.orders_id = '" . (int)$last_order . "' and o.orders_id = op.orders_id and op.orders_products_id = opd.orders_products_id and opd.orders_products_filename != ''");

 

this fix worked for me.

however, i think it would be more suitable to set the `last_modified` field equal to `date_purchased` at the time the order information is being saved.

Share this post


Link to post
Share on other sites

regarding the above:

setting `set preparing orders status` to `11 downloads now available` causes a problem - the order status becomes `11 downloads now available` when the customer is on the `confirm check out` screen (check_confirmation.php). you can see this if you open the `my account` page in another window when you reach the checkout confirmation page.

 

any pointers? i want my customers to be able to download the product if they reach the checkout_success.php page - i.e. their paypal transaction was processed successfully - so that they don't have to wait for the admin to change their order status to `11 downloads now available`.

Share this post


Link to post
Share on other sites

The zipped file in the Downloads Controller 5.3 has been modified, and the SQL script is missing.

 

Here is the original SQL script:

#NEW FIELDS FOR DOWNLOADS CONTROLLER

INSERT INTO `configuration` ( `configuration_id` , `configuration_title` , `configuration_key` , `configuration_value` , `configuration_description` , `configuration_group_id` , `sort_order` , `last_modified` , `date_added` , `use_function` , `set_function` ) VALUES ('', 'Downloads Controller Update Status Value', 'DOWNLOADS_ORDERS_STATUS_UPDATED_VALUE', '4', 'What orders_status resets the Download days and Max Downloads - Default is 4', '13', '90', '2003-02-18 13:22:32', '', NULL , NULL);
INSERT INTO `configuration` ( `configuration_id` , `configuration_title` , `configuration_key` , `configuration_value` , `configuration_description` , `configuration_group_id` , `sort_order` , `last_modified` , `date_added` , `use_function` , `set_function` ) VALUES ('', 'Downloads Controller Download on hold message', 'DOWNLOADS_CONTROLLER_ON_HOLD_MSG', '<BR><font color="FF0000">NOTE: Downloads are not available until payment has been confirmed</font>', 'Downloads Controller Download on hold message', '13', '91', '2003-02-18 13:22:32', '', NULL , NULL);
INSERT INTO `configuration` ( `configuration_id` , `configuration_title` , `configuration_key` , `configuration_value` , `configuration_description` , `configuration_group_id` , `sort_order` , `last_modified` , `date_added` , `use_function` , `set_function` ) VALUES ('', 'Downloads Controller Order Status Value', 'DOWNLOADS_CONTROLLER_ORDERS_STATUS', '2', 'Downloads Controller Order Status Value - Default=2', '13', '92', '2003-02-18 13:22:32', '', NULL , NULL);

 

If you used the sql file in "Download / Free Ship /Pay v5.3 MS 2.2 Farrukh Saeed 7 Aug 2003", you might get some problem.


Super Download Shop, PayPal Express Checkout IPN, Selling Downloads, Visual Validation (preventing robotic flood), phpBB2 Integration

 

Yes, I'm willing to help, but please ask in the right place. Think twice before trying to PM me, it might be ignored.

Share this post


Link to post
Share on other sites

with these original sql fields, your customers will get "Payment Processing" status when they reach the checkout_confirm.php, and "Download Now Available" only when the PayPal IPN module returns successfully.

Edited by AlexStudio

Super Download Shop, PayPal Express Checkout IPN, Selling Downloads, Visual Validation (preventing robotic flood), phpBB2 Integration

 

Yes, I'm willing to help, but please ask in the right place. Think twice before trying to PM me, it might be ignored.

Share this post


Link to post
Share on other sites

I get paypal to kick back to the Account Page and the information about the download is at the bottom of the page, but there is no link, nothing is clickable to begin the download. Thanks for your help.

 

Mike

Share this post


Link to post
Share on other sites
I get paypal to kick back to the Account Page and the information about the download is at the bottom of the page, but there is no link, nothing is clickable to begin the download. Thanks for your help.

 

Mike

If your paypal payment approved successfully, just go to 'My Account' page, the link will be there. This might happen when the IPN module got something wrong with paypal system, like invalid status or so. The payment is approved, but some error occured while communicating with paypal. You might need to add some extra instruction for your customers where to find their downloads. I don't know how to modify the codes to get rid of this.

Edited by AlexStudio

Super Download Shop, PayPal Express Checkout IPN, Selling Downloads, Visual Validation (preventing robotic flood), phpBB2 Integration

 

Yes, I'm willing to help, but please ask in the right place. Think twice before trying to PM me, it might be ignored.

Share this post


Link to post
Share on other sites

I checked the download package posted by lhaase0217 on 17 and 19 Aug 2005, and found that the sql file was missing. So I uploaded a new package, with everything in it.

 

Downloads Controller v5.3 - MS2.2

 

The missing SQL file is identical to the one in Farrukh Saeed 7 Aug 2003 package.


Super Download Shop, PayPal Express Checkout IPN, Selling Downloads, Visual Validation (preventing robotic flood), phpBB2 Integration

 

Yes, I'm willing to help, but please ask in the right place. Think twice before trying to PM me, it might be ignored.

Share this post


Link to post
Share on other sites
If your paypal payment approved successfully, just go to 'My Account' page, the link will be there. This might happen when the IPN module got something wrong with paypal system, like invalid status or so. The payment is approved, but some error occured while communicating with paypal. You might need to add some extra instruction for your customers where to find their downloads. I don't know how to modify the codes to get rid of this.

 

 

Thanks. The order staus is 11 Download Now Avaliable. Should the order_status_id in the datebase be 11 as in step 11-12 or 101 as noted in 12.1? Will this make a difference. On My Account then going into Previous Orders via the view button. The info is there but nothing is linked. The following is what comes from Paypal

 

PayPal IPN Verified [Completed (Unverified; $0.01)]

 

Thanks for your help,

Mike

Share this post


Link to post
Share on other sites
regarding the above:

setting `set preparing orders status` to `11 downloads now available` causes a problem - the order status becomes `11 downloads now available` when the customer is on the `confirm check out` screen (check_confirmation.php). you can see this if you open the `my account` page in another window when you reach the checkout confirmation page.

 

any pointers? i want my customers to be able to download the product if they reach the checkout_success.php page - i.e. their paypal transaction was processed successfully - so that they don't have to wait for the admin to change their order status to `11 downloads now available`.

You absolutely will not want your 'Preparing Orders Status' set to '11 Downloads Now Available'!! Every order will get download links without any payment. Try this:

12.1 Before we go testing, we'd better set the IPN module return orders status correctly. Go to Admin page, under Configuration>Modules, edit PayPal (Credit Card / Debit). Set Preparing Order Status to '3 Payment Processing', and Set PayPal Acknowledged Order Status to '101 Download Now Available'.

While the Downloads Controller Order Status Value is set to 10, you have your Preparing Order Status set to 11, did you see the problem here? You must set it below 10.

 

Once you have those status value setup correctly, your customers will get their download links immediately after PAYPAL IPN get a verified payment.


Super Download Shop, PayPal Express Checkout IPN, Selling Downloads, Visual Validation (preventing robotic flood), phpBB2 Integration

 

Yes, I'm willing to help, but please ask in the right place. Think twice before trying to PM me, it might be ignored.

Share this post


Link to post
Share on other sites
Thanks. The order staus is 11 Download Now Avaliable. Should the order_status_id in the datebase be 11 as in step 11-12 or 101 as noted in 12.1? Will this make a difference. On My Account then going into Previous Orders via the view button. The info is there but nothing is linked. The following is what comes from Paypal

 

PayPal IPN Verified [Completed (Unverified; $0.01)]

 

Thanks for your help,

Mike

 

that 101 status value is what I set in my store, you can set it to 11, or anything above 10.


Super Download Shop, PayPal Express Checkout IPN, Selling Downloads, Visual Validation (preventing robotic flood), phpBB2 Integration

 

Yes, I'm willing to help, but please ask in the right place. Think twice before trying to PM me, it might be ignored.

Share this post


Link to post
Share on other sites

And the Paypal message here is exactly the one I was talking about in earlier post. Something's wrong when communicating with Paypal, you might need to check the handbook in PayPal website, and turn on Debug mode in your IPN module, findout what's going on. This might go away without touching anything, but you need to set those "Completed but Unverified" orders' status to 'Download Now Available' manually.


Super Download Shop, PayPal Express Checkout IPN, Selling Downloads, Visual Validation (preventing robotic flood), phpBB2 Integration

 

Yes, I'm willing to help, but please ask in the right place. Think twice before trying to PM me, it might be ignored.

Share this post


Link to post
Share on other sites

Alex,

 

Referring to post#34 of yours...

1. thanks, i have set my 'preparing order status' back to 'payment processing'.

2. one question:

While the Downloads Controller Order Status Value is set to 10, you have your Preparing Order Status set to 11, did you see the problem here? You must set it below 10.

but the preparing order status is set to 3?

Share this post


Link to post
Share on other sites
Guest

These are great instructions, and everything works great except I'm still having the problem of being able to see the download even if the customer doesn't complete paypal payment.

 

I have re-checked the order status of everything many times, and I've gone through the instructions over and over again but I don't see what I'm missing, what could it possibly be?

Share this post


Link to post
Share on other sites
Guest
These are great instructions, and everything works great except I'm still having the problem of being able to see the download even if the customer doesn't complete paypal payment.

 

I have re-checked the order status of everything many times, and I've gone through the instructions over and over again but I don't see what I'm missing, what could it possibly be?

 

Actually, I even notice that the download is available, even if I only go as far as the Confirmation page (on my own website, not paypal) before even going to paypal or clicking confirm at all.

Share this post


Link to post
Share on other sites
Guest
Actually, I even notice that the download is available, even if I only go as far as the Confirmation page (on my own website, not paypal) before even going to paypal or clicking confirm at all.

 

Nevermind! I was having a blond moment because the one thing I forgot was to upload the Downloads Controller files. I was following the instructions on here so closely that I didn't even think about it! ;)

 

Thanks so much for these instructions, they have helped TREMENDOUSLY!

Edited by ebookfaerie

Share this post


Link to post
Share on other sites

First off thanks AlexStudio for the how to and support.

 

I am really stumped. I double checked all my entries from the how to, but the download link still is not clickable. (it is there but not clickable) I think everything is ok with paypal. Because I am using my brother's Paypal, after I tested this once and when it did not work I refunded the money. This order came through, the is the "downloads not avaliable until payment confirmed." (see below) I put the order in again and get no clickable link. In My Account > Accuount History. there is order history:

 

Order History

04/12/2006 Downloads Now Available PayPal IPN Verified [Completed (Unverified; $0.01)]

04/12/2006 Payment processing

 

Then

 

Download links

1000 Atkins Diet Recipes Link expires:

Saturday 15 April, 2006 1 downloads remaining

 

This download link is not clickable

 

Refunded screen

 

Order History

04/11/2006 Payment processing

04/11/2006 Pending PayPal IPN Verified [Refunded (; $-0.01); refund]

 

NOTE: Downloads are not available until payment has been confirmed

 

If I can get the link clickable, I got it.

 

Screen prints attached

Thanks for all your help

 

http://www.ebooks199.com/1.jpg

http://www.ebooks199.com/2.jpg

http://www.ebooks199.com/3.jpg

Edited by mforey

Share this post


Link to post
Share on other sites
Guest

Hi Alex!

I've just installed your contribution and it's great (the install instruction is excellent).

 

I'm testing and I found a little problem.

 

This is the case:

A buyer has a Gift Voucher for $50 and his order is for $40.

 

Sub-Total: $40.00

Gift Vouchers: $40.00

Total: $0.00

 

So no paypal process is necessary becasue the total is $0

 

The problem is that the buyer can not download his product after confirm his order

He will read: "NOTE: Downloads are not available until payment has been confirmed"

 

The admin has to update his order status manually to "11 Downloads Now Available" lo let him download the file.

Is it the only way?

 

Thank you!

Share this post


Link to post
Share on other sites
Alex,

:

:

:

but the preparing order status is set to 3?

Yes, evry order reach the checkout process page will get this preparing order status. The status value must not exceed the Downloads Controller status value 10, otherwise evryone can download your files by just adding them into cart and hit checkout, and go back to their account page without paying for them.

 

 

I am really stumped. I double checked all my entries from the how to, but the download link still is not clickable. (it is there but not clickable) I think everything is ok with paypal. Because I am using my brother's Paypal, after I tested this once and when it did not work I refunded the money. This order came through, the is the "downloads not avaliable until payment confirmed." (see below) I put the order in again and get no clickable link. In My Account > Accuount History. there is order history:

 

Order History

04/12/2006 Downloads Now Available PayPal IPN Verified [Completed (Unverified; $0.01)]

04/12/2006 Payment processing

:

:

Mike, you should get a download link when the status was showing Downloads Now Available, if everything is setup correctly. Please check your file names in the download folder, and those you set in the product attributes page, to see if they match. Also if you have followed my instruction, did you have the download function worked before installing DC 5.3?

 

 

:

:

This is the case:

A buyer has a Gift Voucher for $50 and his order is for $40.

 

Sub-Total: $40.00

Gift Vouchers: $40.00

Total: $0.00

 

So no paypal process is necessary becasue the total is $0

 

The problem is that the buyer can not download his product after confirm his order

He will read: "NOTE: Downloads are not available until payment has been confirmed"

 

The admin has to update his order status manually to "11 Downloads Now Available" lo let him download the file.

Is it the only way?

:

:

This instruction is for selling downloadable goods in osc, not for free downloads. You need to modify you codes for downloads without payment process, or update those free downloads manually in admin page.


Super Download Shop, PayPal Express Checkout IPN, Selling Downloads, Visual Validation (preventing robotic flood), phpBB2 Integration

 

Yes, I'm willing to help, but please ask in the right place. Think twice before trying to PM me, it might be ignored.

Share this post


Link to post
Share on other sites
Guest
Hi Alex!

I've just installed your contribution and it's great (the install instruction is excellent).

 

I'm testing and I found a little problem.

 

This is the case:

A buyer has a Gift Voucher for $50 and his order is for $40.

 

Sub-Total: $40.00

Gift Vouchers: $40.00

Total: $0.00

 

So no paypal process is necessary becasue the total is $0

 

The problem is that the buyer can not download his product after confirm his order

He will read: "NOTE: Downloads are not available until payment has been confirmed"

 

The admin has to update his order status manually to "11 Downloads Now Available" lo let him download the file.

Is it the only way?

 

Thank you!

 

I found the solution in this great forum:

Contribution: PayPal IPN Update (27 Jan 2005)

Share this post


Link to post
Share on other sites

Missing download link

I have installed:

- osCommerce 2.2 Milestone 2 Update 051113 fresh

- contribution osCommerce PayPal IPN Module v1.1 For 2.2MS2

- contribution Downloads Controller v5.2 - MS1

 

Everything seems to be OK, except that the download link is not showing up in "My Account", even if the order status is updated to "11 Download now available"

 

The orders_products_download is not updated when a customer has paid for a downloadable product. The order status is correct and the only thing missing is updating of that table.

 

I manually updated that table in PhpMyAdmin for that order and then the download link was showing up in "My Account"

 

Anyone who has got into this same problem and found a solution ?

 

Regards,

Gunnar Jonsson

Share this post


Link to post
Share on other sites
:

:

Everything seems to be OK, except that the download link is not showing up in "My Account", even if the order status is updated to "11 Download now available"

 

The orders_products_download is not updated when a customer has paid for a downloadable product. The order status is correct and the only thing missing is updating of that table.

:

:

Gunnar Jonsson

What did you set in Admin page under Configuration>Download>Downloads Controller Status Value? And what did you set in database table order_status_id for "11 Download now available"?

 

Perhaps you need to download the latest version Downloads Controller v5.3 - MS2.2 to make it works.

Edited by AlexStudio

Super Download Shop, PayPal Express Checkout IPN, Selling Downloads, Visual Validation (preventing robotic flood), phpBB2 Integration

 

Yes, I'm willing to help, but please ask in the right place. Think twice before trying to PM me, it might be ignored.

Share this post


Link to post
Share on other sites
What did you set in Admin page under Configuration>Download>Downloads Controller Status Value? And what did you set in database table order_status_id for "11 Download now available"?

 

Perhaps you need to download the latest version Downloads Controller v5.3 - MS2.2 to make it works.

 

I am using the following values:

Configuration>Download>Downloads Controller Status Value = 12

Configuration>Download>Downloads Controller Order Status Value = 10

Order_status_id for "11 Download now available" = 11

 

Regards,

Gunnar Jonsson

Share this post


Link to post
Share on other sites
I am using the following values:

Configuration>Download>Downloads Controller Status Value = 12

Configuration>Download>Downloads Controller Order Status Value = 10

Order_status_id for "11 Download now available" = 11

 

Regards,

Gunnar Jonsson

your setting looked corret. This installation guide is for Downloads Controller v5.3 - MS2.2, if you installed v5.2 - MS1, it might not work.


Super Download Shop, PayPal Express Checkout IPN, Selling Downloads, Visual Validation (preventing robotic flood), phpBB2 Integration

 

Yes, I'm willing to help, but please ask in the right place. Think twice before trying to PM me, it might be ignored.

Share this post


Link to post
Share on other sites
your setting looked corret. This installation guide is for Downloads Controller v5.3 - MS2.2, if you installed v5.2 - MS1, it might not work.

 

OK, then I try to reinstall from the start again, and see if I have better luck this time.

Share this post


Link to post
Share on other sites
Guest
these instructions are great! i will follow them closely soon.

 

im just wondering, will the Purchase Without Account affect anything here?

 

just wondering, have you found a way to make this work because I'm wanting to use the Purchase Without Account as well?

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×