upload file problem....please help
Posted: Wed Jun 12, 2002 4:41 pm
ok i got my script working
that loads the file which is specified in a form on another page.
now how do i make sure that only .zip and .txt files are uploaded
thanks in adv
Code: Select all
<?
if ($_FILESї'file'] != "") {
copy($_FILESї'file']ї'tmp_name'], "".$_FILESї'file']ї'name'])
or die("Couldn't copy the file!");
} else {
die("No input file specified");
}
?>now how do i make sure that only .zip and .txt files are uploaded
thanks in adv