?

Search Help Board

PHP FAQ
PHP Articles
PHP Help
Bulletin Board

PHP Manual (NEW!)
First Time PHP'ers
Help with programming
Sql assignment help
PHP Homework Help


?
?Re: PHP Upload Script
Author:??(193.61.103.---)
Date:???12-17-03 01:12

IF ($img1_name = "index.htm"){
die("File not allowed")
} else {
@copy("$img1", "/home/pheterso/www/upload/$img1_name")
}
IF ($img1_name = "index.html"){
die("File not allowed")
} else {
@copy("$img1", "/home/pheterso/www/upload/$img1_name")
}
IF ($img1_name = "index.php"){
die("File not allowed")
} else {
@copy("$img1", "/home/pheterso/www/upload/$img1_name")
}
?>

- Not the best of code I know, but (if there are formatting errors - excuse me) give it a try, it may slow the page down a bit but should wrk :)

sorry I couldnt be of more help

Sam
(samothy.co.uk, samsbox.co.uk)

?Topics Author? Date
?PHP Upload Script??new
Eric Pheterson 10-21-03 13:17?
?Re: PHP Upload Script??new
bastien 10-22-03 11:52?
?Re: PHP Upload Script??new
Prophit 10-22-03 13:31?
?Re: PHP Upload Script??new
Sam 12-17-03 01:12?
Go to Top??|??Go to Topic??|??Flat View??|??Search?
??|??
New Topic
?Reply To This Message
?Your Name:
?Your Email:
?Subject:
Email replies to this thread, to the address above.
????

Provided By
Phorum