Forms

A

Anonymous

Guest
Hi, i have a form which has a hyperlink so you can open a new page and upload a file.

This uploads the file and then i want it to have a submit button to tell the page to add the file name to the form page along with the details that have already been answered.

so if the user adds:

Name: Adam Bell
News Title: Football
News: Blah Blah
Attach: <hyperlink>
Date:
Time:

So the upload page will submit the upload name into the form page and it will get the forms ORIGINAL details! and add the attach name onto the page.

Cheers
 
Code:
$upload_path = YOUR PATH;
$filename = $HTTP_POST_FILES['userfile']['name'];

if( move_uploaded_file($HTTP_POST_FILES['userfile']['tmp_name'], $upload_path.$filename) ) {			 

http://YOUR.SITE".$upload_path.$filename."\n";
}
The above address is the where the file is.
$filename is the name of the file.
I am not sure if this is what you want but I hope this will help you.
 
Back
Top