Only registered users can upload

All support enquiries for DFH go in here...

Only registered users can upload

Postby Snapper » Sun Jan 22, 2012 9:56 pm

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.
Snapper
Premium
 
Posts: 2
Joined: Sun Jan 22, 2012 6:14 pm

Re: Only registered users can upload

Postby SamEA » Sun Jan 22, 2012 11:09 pm

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.
SamEA,
DaddyScripts' Admin & Developer.

Require a PHP or general IT freelancer? Don't hesitate to PM me.
User avatar
SamEA
Site Admin
 
Posts: 1165
Joined: Sat Feb 19, 2011 7:51 pm

Re: Only registered users can upload

Postby Snapper » Mon Jan 23, 2012 2:02 pm

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
Snapper
Premium
 
Posts: 2
Joined: Sun Jan 22, 2012 6:14 pm

Re: Only registered users can upload

Postby SamEA » Mon Jan 23, 2012 4:33 pm

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.
SamEA,
DaddyScripts' Admin & Developer.

Require a PHP or general IT freelancer? Don't hesitate to PM me.
User avatar
SamEA
Site Admin
 
Posts: 1165
Joined: Sat Feb 19, 2011 7:51 pm

Re: Only registered users can upload

Postby DirectProject » Sun Jul 01, 2012 4:24 pm

//*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
Image
User avatar
DirectProject
Standard Member
 
Posts: 12
Joined: Sat Jun 30, 2012 11:37 pm

Re: Only registered users can upload

Postby SamEA » Mon Jul 02, 2012 3:47 pm

Please re-upload and replace ./upload.php.

Afterwards, follow these instructions: viewtopic.php?f=9&t=34
SamEA,
DaddyScripts' Admin & Developer.

Require a PHP or general IT freelancer? Don't hesitate to PM me.
User avatar
SamEA
Site Admin
 
Posts: 1165
Joined: Sat Feb 19, 2011 7:51 pm

Re: Only registered users can upload

Postby DirectProject » Sat Jul 07, 2012 8:13 pm

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
Image
User avatar
DirectProject
Standard Member
 
Posts: 12
Joined: Sat Jun 30, 2012 11:37 pm

Re: Only registered users can upload

Postby SamEA » Tue Jul 10, 2012 2:39 am

You are indeed correct Adam. Thank you for reporting that typo error. I have now modified the code.
SamEA,
DaddyScripts' Admin & Developer.

Require a PHP or general IT freelancer? Don't hesitate to PM me.
User avatar
SamEA
Site Admin
 
Posts: 1165
Joined: Sat Feb 19, 2011 7:51 pm


Return to Daddy's File Host v1.X

Who is online

Users browsing this forum: No registered users and 12 guests

cron