View Full Version : Download Controller Not working

11-28-2005, 08:24 PM
Well I figured out the error message I am seeing at first was do to a misplaced comment line in the 'download.php' file, but I still dont see why the download link isnt showing even after fixing this issue with the error message. I have set the status to the default to make the file availabe, and enable the download option.

11-29-2005, 06:43 PM
Can I get some assitance please?

am trying to make the oscmax let users download files after payment but the link isnt showing up in the store. I have enable the download option in the admin section and set the default status as describe and I still dont see a link when the item is process and paid for. The attribute setting have been set as describe since everything in the store is dowloadable no products have weight. The file is available in the download folder.

11-29-2005, 08:43 PM
http://oscdox.com/modules.php?op=modload&name=phpWiki&file=index&pag ename=DownloadSetup

12-01-2005, 06:18 AM

I couldn't get this working either. I think that the page you referred to is a little out of date.

It may be that I don't have an Orders Status of Delivered, or that it doesn't have the right ID, because there is some logic involving Orders Status codes.

That's why I offered $50 for documentation complete enough to let me get this working, and that offer stands.


12-01-2005, 09:39 AM
On default installs, the instructions that I referred to always work for me.

When I get some time I will go through them step by step to see where they can be clarified and improved. You may also want to get a copy of the download controller setup instructions, as the entire rationale and all requirements for the mod are fully covered there. I will see if I can dig up a copy and post them on the wiki page too...

12-01-2005, 11:02 AM
Things aren't always that neat and tidy, unfortunately.

I imported a lot of my data from 1.7, and may have deleted some of the important status codes. I know I added some, too.

I have the OSCommerce Manuals from Kerry Watson for CRE, and there's not much there, either.

I am going to revisit this when *I* get some time, too.


12-03-2005, 05:57 PM
Well unlike many people I have to post the fix tha tworked for me on this issue. An I will document it as best I can. I search for hours for the fix...

Well first the stock version has a comment line in the wrong place around line 76 in the /includes/modules/download.php

// LINE REMOVED: MOD - Downloads Controller Show Button

This line needs to be moved and put before the


just above it. This way it wont show on the download page,making things look all weird. Now beside the fact that you have to enable the feature in the configuration.

The thing they dont tell you is that you have to delete all the existing attributes found in the stock version. Then make a new set of attributes for your products, and make sure all the files you plan to link to your items exist in the download folder. That you have the perissions set on the pub folder to chmod 706 or 777 depending on your server.

Most of this is in the docs expect the deletion of all the stock attributes from the database and then creation of new ones. Said thing is if you happen to be one of those people that are adding downloads as a post setup then you still have to delete all the attributes first then renter them. It works best if you do this from a stock install.

12-04-2005, 05:35 AM
Mr HipHop,

I appreciate you passion and persistence.

Is your Download system finally working? If so, can you post a screen shot with your settings, and a list of your orders_status codes (or are they the default ones from RC1 or RC2?. Those statuses interact with the Download Controller some how.

I am dreading the idea of dropping all my attributes, but will, if it gets this module working. What did you use for your Option Name and Option Value?

I don't know if you saw, but I posted an offer of $50 to anyone who came up with the clues to help me get this going. That might make the hours you spent less painful.


12-04-2005, 09:49 AM
I used the following setting on my site.

Enable download true
Download by redirect true
Expiry delay (days) 7
Maximum number of downloads 3
Downloads Controller Update Status Value 100000
Downloads Controller Download on hold message <BR><font color="FF0000">NOTE: Downloads are not available until payment has been confirmed</font>
Downloads Controller Order Status Value 2

Now in the IPN payment modules you have to set the final value to "Processing" which is the # 2 order status. Don't set it to anything like Delivered if your using IPN downloaded items. Now, if you got check or money orders then set it to "Pending" of course then when you get the money change it to "Processing". The redirect works with linux servers and the /pub folder has to have writable permissions (chmod 777) to work promperly.

Here is a screen shot of my attributed with the names I used and you can see I deleted all the old ones first. You will see that I have named the primary option "Download", and the actually option shown to the end users "Download: Zip" and "Download: MP3".

http://img27.paintedover.com/uploads/thumbs/27/screenshot.jpg (http://paintedover.com/uploads/show.php?loc=27&f=screenshot.jpg)

Now, what I can say is use the utility to backup your current database. I assume you know that the folder in the admin section /backup has to be writeable (chmod 777). Then make the changes I have described. test it on a product in your store. Well then if it dont work for you then you can always restore the backup and post here again for another solution.

As for the insentive to help you well would have to consider that a donation because open source is free and so is the support for it. I use the support for free for others like me, and I can only in all right give it to others like me for free. So if you want to make a donation for my assitance then thanks for your support, but I won't charge you for helping you.

08-09-2006, 08:49 PM
Found this on the OSC site. Perhaps it might help others setup downloads and PayPal.