My form below is written in Javascript... *this is to prevent people without Javascript installed from uploading files *because they could be fake or worse*, plus I wanted to experiment with javascript... so thats why its all in document.write form... sorry but its also a little easier to write.
Now thats the whole form... theres only a couple of things I want to validate using PHP.Code:document.write("<div class='pureadd'>") document.write("<form action='send.php' method='post' class='form'>") document.write("<h1>Upload Your File</h1>") document.write("<fieldset><legend>Step 1</legend>") document.write("Only put what is true, if you put any fake information your upload will be ignored") document.write("<br>Your First Name:") document.write("<br><input type='text' name='FName' class='input'/>") document.write("<br>") document.write("<br>Your Last Name:") document.write("<br><input type='text' name='LName' class='input'/>") document.write("<br>") document.write("<br>Your Age:") document.write("<br><input type='text' name='Age' class='input'/>") document.write("<br>") document.write("<br>Your Email Address:") document.write("<br><input type='text' name='EmailAddress' class='input'/>") document.write("</fieldset>") document.write("<fieldset><legend>Step 2</legend>") document.write("<br>Your File's Title:") document.write("<br><input type='text' name='Title' class='input'/>") document.write("<br><p>This is what the title of the video is going to be called, ") document.write("<br>Is your Video Amazing or Funny?") document.write("<br><input type='checkbox' value='Amazing' name='Video Type'/> My Video is Amazing. ") document.write("<br><input type='checkbox' value='Funny' name='Video Type'/> My Video is Funny. ") document.write("<br><input type='checkbox' value='Unknown' name='Video Type'/> I have no clue. ") document.write("</fieldset>") document.write("<fieldset><legend>Step 3</legend>") var d = new Date() document.write("<br>Time Page Loaded:") document.write("<br><input type='text' value='"+Date()+"' name='time' readonly='true' class='input'>") document.write("<br>") document.write("<br>By submitting your file you agree with with our Terms of Service, if you haven't read them, please read them before submitting your file.") document.write("</fieldset>") document.write("<fieldset><legend>Step 4</legend>") document.write("<br>Select your file type:") document.write("<br><input type='checkbox' value='Video' Name='Filetype'> Video File") document.write("<br><input type='checkbox' value='Picture' Name='Filetype'> Picture File") document.write("<br><input type='checkbox' value='Audio' Name='Filetype'> Audio File") document.write("<br>") document.write("<br>Upload Your File:") document.write("<br><input type='file' value='' name='FILENAME' id='file'/>") document.write("<br>")
First one is going to be to make sure everythings not blank...
Second one could it deal with the age... because I don't want people sending in 999 as an age, so is there a way to put a max limit like (110) because I highly doubt the oldest person in the world can submit files, I bet he/she has other things todo.
Third the last one is the
is there a way inorder to get this to filter out certain files... I don't know PHP, and my server is holding itself hostage and preventing me from viewing PHP codes... so if you could check before you post it that would be awesomeCode:document.write("<br><input type='file' value='' name='FILENAME' id='file'/>") document.write("<br>")
THANKS TO ALL!


Reply With Quote


Bookmarks