how to uploade video in php????
Answer / rashmi bajpai
On php coding file like uploaded.php<?php
$target_path="../upload/";//this is the name of that folder
in which we r uploading our video.//
$arg=$_FILES['uploadedfile']['tmp_name'];
if(move_uploaded_file($tmp,$target_path))
{
echo "The file". $_FILES['uploadedfile']['name']."has been
uploaded";
}
else
{
echo"there was an error in uploading";
}
?>
On other html file like uploaded.php:
<html>
<form enctype="multipart/form-data" action="uploaded.php"
method="post">//file should always be uploaded by post method.
<input type="hidden" name="MAX_FILE_SIZE" value="100000"/>
Choose a file to upload:
<input name="uploaded file" type="file"/> <br>
<input type="submit" value="upload file"/>
</form>
</html>
| Is This Answer Correct ? | 24 Yes | 3 No |
What are the advantages of PHP over HTML?
11 Answers Infosys, Torque Infotech,
What will replacement of localhost username and password on submission a site
What is a query give example?
Which functions are used to remove whitespaces from the string?
What is var_dump function in php?
What are the design patterns in php?
How do you put a space in html?
Do you know when sessions ends?
What are php magic methods?
What is the difference between echo and print statement?
11 Answers Rushmore Consultancy,
What is the difference between get and post method in php?
What is the default session time in PHP and how can I change it?