|
Darkshadow
|
 |
« Reply #2 on: August 07, 2009, 04:53:43 am » |
|
ok, i understand,
with the download button simply check a attribut (maybe: multipart yes/no) then you have to decide if no multipart: download the file as useal or if multipart: generate a multipartdownloadpage from the selected download and give access to this multidownloadpage from the selected download where all the parts will be listed and can be choosed for download, add after every part again the downloadbutton.
Multiparts have only to charge one times, not for every part, simple add an attribute /flag that user idxx allready charged for this download, after download all parts, deleted this flag.... Every part downloaded have to be added in the databse,
Maybe a multipart download (here in example its id 1) consist of 4 files and user has downloaded part 1 and 2, then you can add and alter this tables in database:
in the table "smf_down_file" add this rows:
id_Multipartdownload multiparts 1 4 |_____ = only the id of the multipartdownload, next added multipartdownload will be id 2 and so on....
in the "smf_members" table add this rows:
payed_multiparts_downloads 1 <-------------------------- this is the id from the payed multipartdownload id_Multipartdownload from "smf_down_file" table
parts_downloaded 1,2 <-------------------- if reached 1,2,3,4 then download complete and delete the id_Multipartdownload value from row "payed_multiparts_downloads" also delete all values in row parts_downloaded
i think this could be a way...
Darkshadow
|