php forum
php mysql forum
php mysql smarty
 
Page 1 of 2 1 2 >
Topic Options
#224833 - 09/20/02 02:31 AM File Download Page v1.0
Aglavalin Offline
Enthusiast

Registered: 06/18/02
Posts: 394
Loc: Southern California

   File Download Page v1.0 to Del.icio.us Add to del.icio.us
  Digg File Download Page v1.0 Digg it
Mod Name / Version - File Download Page v1.0<br /><br />Description - Allows administrator to setup a Download page, seperate from UBBT, where allowed users can upload and maintain files and descriptions. Files can be categorized, and will display who uploaded them, and a download count. Uploaders can return and edit, delete, or upload a newer version of the file. Admin has full control with admin pages to edit and delete files. Custom settings include file size limit and file type restrictions.<br /><br />Example - http://www.newoutriders.org/downloads/index.php<br /><br />Pre-requisites - none<br /><br />Author - Aglavalin, aka Steve Stout<br /><br />Files Altered - config.inc.php<br /><br />Database Altered - Only two tables are created, thus, very removable.<br /><br />New Files - doeditcategories.php, doeditmyuploads.php, douploadfile.php, download.php, editcategories.php, editdownloads.php, editmyuploads.php, getdownload.php, index.php, updatedownload.php, updateupload.php, uploadfile.php<br /><br />Credits: Dslam for suggesting this addon.<br /><br />Notes: All new files go into their own directory, i.e. domain.com/downloads. The files are designed to work with an installation of IIP 4.3, so if you are using a different page layout, you will need to edit each page except for download.php to match your site.<br /><br /><br />Here is what I believe to be a good working copy.


Attachments
56942-FileDownloadPage_v1.0.zip (103 downloads)


Top
#224834 - 09/20/02 09:29 AM Re: File Download Page v1.0 [Re: neuron]
msula Offline
Addict

Registered: 02/18/02
Posts: 1969
Loc: Lansing, Michigan
Holy crap, that's awesome! Now, not to be picky... but do you think in the future you could allow the admin to setup categories? Say documents, programs, etc.. <br /><br />Thanks for the good mods lately!

Top
#224835 - 09/20/02 09:41 AM Re: File Download Page v1.0 [Re: neuron]
Gardener Offline
Addict

Registered: 05/11/99
Posts: 1956
Loc: Sweden, Uppsala
Nice one! I'll definitely try this one out as soon as I've updated my own mods.
_________________________
/Gardener | Complete list of my mods

Top
#224836 - 09/20/02 10:37 AM Re: File Download Page v1.0 [Re: c0bra]
JoshPet Offline
I type Like navaho

Registered: 11/29/01
Posts: 11330
Loc: Charlotte, NC
Very cool.<br />I might check this out this weekend, as I'm thinking about a use for this for Video Files on my site. <img src="/forum/images/icons/smile.gif" alt="" /><br />Thanks.
_________________________
Joshua Pettit
www.JoshuaPettit.com
My abilities are for hire.

Top
#224837 - 09/20/02 11:56 AM Re: File Download Page v1.0 [Re: Daine]
AllenAyres Administrator Offline
I type Like navaho

Registered: 03/10/00
Posts: 25432
Loc: Texas
Yes, very nice <img src="/forum/images/icons/laugh.gif" alt="" /><br /><br />I agree with Jeremy, categories would be a very nice next step <img src="/forum/images/icons/smile.gif" alt="" />
_________________________
- Allen wavey
- What Drives You?

Top
#224838 - 09/20/02 02:38 PM Re: File Download Page v1.0 [Re: SurfMinister]
Dslam Offline
Member

Registered: 06/05/01
Posts: 246
Loc: USA
Cool deal thanks <img src="/forum/images/icons/smile.gif" alt="" />

Top
#224839 - 09/20/02 03:03 PM Re: File Download Page v1.0 [Re: interforos]
Aglavalin Offline
Enthusiast

Registered: 06/18/02
Posts: 394
Loc: Southern California
It does have categories. You need to have admin authority to see the admin links show up on the index.php page. But it does put everything on one page. I plan on giving the option to make each category a seperate page in the next version, perhaps multiple pages with a max file limit admins can set. <br /> <br />This addon ended up being quite massive, so I had to set some limits to get it done! LOL <br /> <br />It will not let you delete a category if files are still in it. If you rename a catagory, it will update the category name for each file in the database. I tried to make it foolproof, because if a file has an invalid category name, it will not show up on the list as a download. Editing the table by hand is such a pain. <br /> <br />Please let me know what else this addon could use, maybe I'll add it next version.


Edited by Aglavalin (09/20/02 03:15 PM)

Top
#224840 - 09/20/02 03:44 PM Re: File Download Page v1.0 [Re: neuron]
Aglavalin Offline
Enthusiast

Registered: 06/18/02
Posts: 394
Loc: Southern California
OK, seems like I messed up the second table creation syntax. I'll fix it and make the ubbt path a config file feature and reupload an updated version today!<br /><br />The second table creation syntax should be:<br /><br /><pre><font class="small">code:</font><hr><br />CREATE TABLE w3t_Dlcat (<br /> DL_CategoryName varchar(30) NOT NULL,<br /> DL_CatOrder tinyint(3) Default '0' NOT NULL,<br /> KEY DL_CategoryName (DL_CategoryName)<br />);<br /></pre><hr>

Top
#224841 - 09/20/02 04:00 PM Re: File Download Page v1.0 [Re: neuron]
Aglavalin Offline
Enthusiast

Registered: 06/18/02
Posts: 394
Loc: Southern California
Updated directions with a fix to the second table creation syntax.<br /><br />The path to the main.inc.php file can not be put in the config file because these files are in a different directory than UBBT. Perhaps in a future release I will create a seperate config file for this addon, which would remove the need to edit this in each file. I gotta think about this a bit.<br /><br />The $BasicTitle can be cusomized for each page, thus I prefer to leave it in each page for full feature. The pals path is probably gonna be edited out by many, I'll wait for some more feedback on this before making any changes.


Attachments
56968-FileDownloadPage_v1.1.txt (104 downloads)


Top
#224842 - 09/20/02 06:06 PM Re: File Download Page v1.0 [Re: neuron]
Dslam Offline
Member

Registered: 06/05/01
Posts: 246
Loc: USA
she's a working great <img src="/forum/images/icons/grin.gif" alt="" /> <br />thanks <br />if your runing ipp5 the pal menu does not work .<br />so remove it or find a way to fix it .<br />

Top
#224843 - 11/17/02 08:50 PM Re: File Download Page v1.0 [Re: neuron]
Gardener Offline
Addict

Registered: 05/11/99
Posts: 1956
Loc: Sweden, Uppsala
I just made a trial installation of this, finally, and found some minor caveats.<br /><br />First, the category list numbers need to start from 0 and be consecutive numbers, which wasn't entirely clear, should be in the description. Or even better, why not just sort by the number and do the loop on the number of rows returned?<br /><br />Also, the check for if the user is in the right group isn't entirely correct. If the group chosen is first on the list, php returns a false value (position 0). Just change the following:<br /><br /> if (!strpos($user['U_Groups'],$dlgroup)) {<br /><br />to this, in all pages:<br /><br /> if (strpos($user['U_Groups'],$dlgroup) === false) {<br /><br /><br />It was also a bit of a pain that the configuration strings weren't the same in all files, it would have made it so much easier to do a search and replace. =]<br /><br /><br />I think it might be a good idea to add the updated instructions to the main package in the first post of this thread.
_________________________
/Gardener | Complete list of my mods

Top
#224844 - 12/03/02 09:46 AM Re: File Download Page v1.0 [Re: c0bra]
Lerosia Offline
User

Registered: 08/20/02
Posts: 37
Loc: Vancouver
I am trying out this mod but not sure I understand this line:<br /><br /> $palspath = "c:/inetpub/wwwroot/YOURDOMAIN.COM/pals/";<br /><br />"To match your paths. If you are not using IIP 4.3, then remove the '$palspath... line and replace with what you are using for menu/page layout. There is an include of menupal.php which you will want to edit or remove if not using IIP 4.3. Change the $BasicTitle to what you want to call each page, or leave them all the same for the whole section."<br /><br /><br />Question 1 What is IIP 4.3?<br /><br />Question 2 What is a palspath?<br /><br /> Question 3 What is it referring to when it says "remove the '$palspath... line and replace with what you are using for menu/page layout? <br /><br />What would I be using for menu/page layout in UBBT?<br /><br />Question 4 In the line: $config['dlgroup'] = "5";<br /><br />What the heck does 5 represent?<br /><br />So, before I complete this one, is the a new version with Gardener's minor caveat suggestions above?<br /><br />I havent even gotten to that issue yet <img src="/forum/images/graemlins/smile.gif" alt="" /><br /><br />Thanks in advance<br /><br />Lerosia<br /><br /><br />
_________________________
[:"red}Ifyouwanttomakeyourcomputergoreally,reallyfast,thowitoutthewindow[/color"]

Top
#224845 - 12/03/02 10:22 AM Re: File Download Page v1.0 [Re: Calis]
Gardener Offline
Addict

Registered: 05/11/99
Posts: 1956
Loc: Sweden, Uppsala
Here are some answers for you:<br />
  1. IIP 4.3 is JustDaves Integrated Index Page add-on, which can be found in the Forum Design Integration board. The latest version is 5.x which I think might not be completely compatible with this script. It might be though.<br />
  2. palspath is from the IIP add-on and is the path to where all the scripts for that add-on is located. Usually it is a sub-directory of the ubbthreads directory called "pals".<br />
  3. It means that in order to get a menu if you don't have the IIP add-on you will have to create your own menu with at least a link to the main page of this download add-on.<br />
  4. The number is the number of the user group that users have to be in to be allowed to download. If you want everyone to be able to download, set it to 3, which should be the regular user group. If you want to use some other group, you can find out which number it has by running the query below in the Admin->SQL Command page:<br />select * from w3t_Groups<br />
  5. I don't think anyone has done any work on this, and I'm not using it myself either, I just tried it out to see if it was what I wanted. I will probably wait for the extended download functions which are going to be added to a future version of JustDaves IIP add-on. The script should work without the things I mentioned, those were just some tips to make life easier.<br />
_________________________
/Gardener | Complete list of my mods

Top
#224846 - 12/03/02 05:44 PM Re: File Download Page v1.0 [Re: c0bra]
Lerosia Offline
User

Registered: 08/20/02
Posts: 37
Loc: Vancouver
AHHHH..no wonder I couldnt figure it out.<br /><br />This should teach me a valuable lesson about *BETA*<br /><br /><img src="/forum/images/graemlins/smile.gif" alt="" /><br /><br />Thank you Gardener..I will check out the IIP as well<br /><br /><br />Lerosia
_________________________
[:"red}Ifyouwanttomakeyourcomputergoreally,reallyfast,thowitoutthewindow[/color"]

Top
#224847 - 12/03/02 08:36 PM Re: File Download Page v1.0 [Re: Calis]
Dslam Offline
Member

Registered: 06/05/01
Posts: 246
Loc: USA
this download addon works fine .<br />if you don't have ipp then you have to open each page & edit out the calls to the menupal <br /><br />

Top
#224848 - 06/21/03 01:28 AM Re: File Download Page v1.0 [Re: neuron]
yors Offline
Member

Registered: 10/09/01
Posts: 152
OK Josh, saw you online right after I posted the suggestion, reading this. So am here too. Silly me <img src="/forum/images/graemlins/tongue.gif" alt="" /><br /><br />Reading it too...
_________________________
Yors Truly

Who? Me? Worry?

Top
#224849 - 06/21/03 01:28 AM Re: File Download Page v1.0 [Re: phill]
JoshPet Offline
I type Like navaho

Registered: 11/29/01
Posts: 11330
Loc: Charlotte, NC
he he<br /><br />That's OK - this is an old one - took me a bit to dig it up, but I thought I remembered it. <img src="/forum/images/graemlins/wink.gif" alt="" />
_________________________
Joshua Pettit
www.JoshuaPettit.com
My abilities are for hire.

Top
#224850 - 07/04/03 02:05 PM Re: File Download Page v1.0 [Re: Daine]
oceanwest Offline
Enthusiast

Registered: 04/25/02
Posts: 490
Loc: Escondido, CA
Ok I added this and it doesn't work So now I want to get rid of it and undo the database changes... How do i do this?
_________________________
FM Forums
Largest Online FileMaker Community
http://www.fmforums.com

Top
#224851 - 07/04/03 04:44 PM Re: File Download Page v1.0 [Re: sdf123]
omegatron Offline
Member

Registered: 04/05/01
Posts: 3440
Loc: abingdon,md
Delete those tables in your database <img src="/forum/images/graemlins/wink.gif" alt="" /><br /><br />You can use phpmyadmin http://www.phpmyadmin.net or any other brand you use
_________________________
Chuck S

DIVE IN AND VISIT ME:

Omegatron\'s Reefs

Administrator at ReefTalk

Top
#224852 - 02/16/04 01:50 AM Re: File Download Page v1.0 [Re: sf49rminer]
smilesforu Offline
Junior Member

Registered: 01/31/02
Posts: 676
Anybody running this on 6.4?

Top
Page 1 of 2 1 2 >


Who's Online
1 Registered (blaaskaak), 29 Guests and 5 Spiders online.
Key: Admin, Global Mod, Mod
Shout Box

Latest Posts
Blogs, love em or hate em?
by AllenAyres
10/07/08 02:05 PM
What do you use to edit the files
by Ian_W
10/05/08 03:33 PM
BeyondCompare v3.00
by Ian_W
10/05/08 03:32 PM
Glossy Black Theme with Image Reflection
by Gizmo
10/05/08 02:17 PM
ShareThis
by Gizmo
09/28/08 05:06 AM
[7.3] Viewing MySQL logfiles made easier
by AllenAyres
09/27/08 09:57 PM
Looking for a simple upload script
by Murphdog
09/26/08 08:45 PM
New Mods
[7.3] Viewing MySQL logfiles made easier
by blaaskaak
09/24/08 05:39 PM
[7.3.1] add search to showmembers page
by blaaskaak
09/07/08 04:50 AM
Multiple Identity Detector
by
12/30/06 06:39 PM
Newest Members
pisa666, ghengis317, NitroX, Dogan, EliYah-
13345 Registered Users
Top Posters Last 30 Days
AllenAyres 11
blaaskaak 7
FREAK1 5
Chris Bale 4
Ian_W 4
tackaberry 4
Gizmo 4

 

 

 
fusionbb message board php hacks