Page 1 of 1

Only registered users can upload

PostPosted: Sun Jan 22, 2012 9:56 pm
by Snapper
Firstly let me say how much i like your script, in fact i like it so much i have just donated which doesn't happen often.

I would like to know if it's possible to allow only registered/logged in users to upload files? I've checked out the link here http://www.daddyscripts.com/forum/viewtopic.php?f=9&t=34 but that only seems to be for users of admin status unless i'm missing something. Also, is it possible to disable or adjust the "You Will Be Redirected To Homepage In 10 Seconds." message. Ideally i would like to redirect immediately.

Re: Only registered users can upload

PostPosted: Sun Jan 22, 2012 11:09 pm
by SamEA
I'm very glad to hear you're enjoying our script. Your contribution will help DaddyScripts expand and stay alive :).

In regards to only registered users being able to upload; in the MOD guide, replace all code containing the following line:
Code: Select all
if(isset($_SESSION['logged_in']) && $_SESSION['logged_in']==md5(md5($adminpass))) {
with
Code: Select all
if((isset($_SESSION['user']))) {
.

I haven't tested this myself, however in theory that should work. Let me know how it goes.

Re: Only registered users can upload

PostPosted: Mon Jan 23, 2012 2:02 pm
by Snapper
Thank you for the reply.
Unfortunately the upload system is now completely broken for registered users or not. HTML upload gets stuck on "Uploading..." and flash diverts to upload.php?do=verify which gives a "Remote server or file not found" error.
Besides " if((isset($_SESSION['user'])) { " everything is as the MOD guide.

PM sent with site address. Thanks

Re: Only registered users can upload

PostPosted: Mon Jan 23, 2012 4:33 pm
by SamEA
The change I provided shouldn't cause that of a major problem. I'm assuming this MOD isn't compatible or you have missed a few things. Will apply the MOD myself when near a PC and fix any compatible issues if found. Thank you.

Re: Only registered users can upload

PostPosted: Sun Jul 01, 2012 4:24 pm
by DirectProject
//*Hello, I've had ago at this, its working fine but i get an error?

ill attach a Image >>> -- http://thatfile.co.cc/images/669606Untitled.png -- <<

*//

Sorry for the confusion BUT, Is it possible that you can edit the files your self and upload them? I'm easily Confused and i dont want to mess up the site as many users desire the site, the main reason for this is users that are not registering are uploading ilegal stuff to the site, I don't fancy getting done for this shissle... Is it possible for the image upload to?

Greatly appreciated.

Thanks, Adam

Re: Only registered users can upload

PostPosted: Mon Jul 02, 2012 3:47 pm
by SamEA
Please re-upload and replace ./upload.php.

Afterwards, follow these instructions: viewtopic.php?f=9&t=34

Re: Only registered users can upload

PostPosted: Sat Jul 07, 2012 8:13 pm
by DirectProject
Hello, I faintly found the problem, you simply forgot a bracket ")", here is what it should look like.


Code: Select all
if((isset($_SESSION['user']))) {


Thanks, Adam watts

Re: Only registered users can upload

PostPosted: Tue Jul 10, 2012 2:39 am
by SamEA
You are indeed correct Adam. Thank you for reporting that typo error. I have now modified the code.