• Howdy! Welcome to our community of more than 130.000 members devoted to web hosting. This is a great place to get special offers from web hosts and post your own requests or ads. To start posting sign up here. Cheers! /Peo, FreeWebSpace.net
managed wordpress hosting

Php help

Status
Not open for further replies.
Hi, first of all, thats the zip file for phpuploader.... you have to unzip it... then run the included files.
 
yea i did that uploaded them ,it all worked but now i need some code to show the files
that have been uploaded. so they can view them :p
 
Ok give a link to the actual upload screen so we can test it out, or PM me with it if you like, so I can see how it works.
 
just checked out the script, and for your solution its VERY easy.

Open up the UPLOADER.php file and look for the part where it gets successfully uploaded (its like lines 85-92)
Alright now under the line "copy ($picture3, "$ADMIN[directory]/$picture1");"
place this:
$error .= "<img src='$ADMIN[directory]/$picture1'><BR>";
and that is all.
 
Polykranopalous said:
just checked out the script, and for your solution its VERY easy.

Open up the UPLOADER.php file and look for the part where it gets successfully uploaded (its like lines 85-92)
Alright now under the line "copy ($picture3, "$ADMIN[directory]/$picture1");"
place this:
$error .= "<img src='$ADMIN[directory]/$picture1'><BR>";
and that is all.

I need it like so it show all the file titles then you can right click on it to save it or get the location so people know where it is :biggrin2:
 
mami,

You could resolve this problem with a simple file directory listing script. Go to This URL to find a tutorial on how to make a readdir function work.
 
Not unless they cannot see certain files.

This is why,

$handle !== index.php (file_dir_list) && $handle !== conf_global.php (IPB stuff) && $handle !== mysql_driver.php

This goes in as with any other files you dun want to show in the readdir thing. :p

fileupload() can be set the same way I believe.
 
ryza said:
Letting users upload into a web accessible folder is a security risk*

Not really if need to put in a password to upload a file :p
or if you put it in a password protected directory

DarkBlood said:
Not unless they cannot see certain files.

This is why,

$handle !== index.php (file_dir_list) && $handle !== conf_global.php (IPB stuff) && $handle !== mysql_driver.php

This goes in as with any other files you dun want to show in the readdir thing. :p

fileupload() can be set the same way I believe.

Thanks for your help
done now

Could some moderator close this topic please? :tired2:
 
Status
Not open for further replies.
Back
Top