php upload script

   • questions and answers  • distance calculator  • maps
   



CATEGORIES
EXCEL TUTORIAL
SQL TUTORIAL
WEB INFORMATION
WINDOWS
JAVASCRIPT SCRIPTS
COMPUTER SECURITY
GRAFIC DESIGN
HTML
PHP
CSS STYLE
ATLAS OF THE WORLD
DEVELOPER
PHOTOSHOP
MAGAZINE
TOP LISTS
LATEST ARTICLES
check if user like page facebook online tool
base64 decode online free tool javascript
base64 encode online free tool using javascript
array slice php funtion
how to tell google to not change your page title with dmoz title
md5 hash generator online tools windows linux c php
remove duplicates in html lines online javascript
documentgetelementbyid()innerhtml javascript set example
how to block processes from starting and running in windows xp
list of us american presidents with pictures
  home   PHP » PHP UPLOAD SCRIPT
google ads

PHP UPLOAD SCRIPT


Views: 1238
In this tutorial we will learn how to transfer a file from the computer to the server.
The first part of script is the form of upload.

We will use for this :
  • form (included in .html or .php page)
  • php upload script
  • and folder ( directory ) for uploaded files.

STEP 1:
Create the form.
If you use Html pages you have to create a new html page named upload.html
Open this page into an editor ( notepad, dreamweaver ) and copy the next code inside:



 code:
===============

<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
<title>Upload form html</title>
</head>
<body>
<form id="form1" name="form1" enctype="multipart/form-data" method="post" action="upload.php">
<label>
<input type="file" name="userfile" value=""/>
<input type="submit" value="upload file" />
</label>
</form>
</body>
</html>

=================



The result is :

( Note: If you use Php pages you can insert the html form code in the same page with the script)

The code for form in php page can be the same like the html code or just the form without the html head, tags, css etc. :


====================== 

<? <form id="form1" name="form1" enctype="multipart/form-data" method="post" action="upload.php">
<label>
<input type="file" name="userfile" value=""/>
<input type="submit" value="upload file" />
</label>
</form>
?>

 ====================


 

» CREATE HTML ( PHP ) FORM
» STEP 2 : VALIDATION PHP : CHECK FILE EXTENSION IF IS  ALOWED / NOT ALLOWED  TO BE UPLOADED
» STEP 3 : VALIDATION PHP : CHECK IF A FILE WITH THE SAME NAME EXIST ON SERVER
» STEP 4 : VALIDATION PHP : CHECK THE FILE MAXIMUM SIZE
» STEP 5 : MOVE UPLOAD FILE IN UPLOAD DIRECTORY ON SERVER


Leave a comment

Your name *
Your comment *
   Anti Spam code *

.
Articles related to PHP UPLOAD SCRIPT
Zero result!

Tags:upload script php,html upload script,html upload form,
2 comments

added by: rafiel date: 07-08-10

How about if i upload multiple file,,,, becouse im always searching on the internet, it's only shows 1 upload file script,,, how about for multiple, can u help me giving script for multiple file upload with validation????,,, thanks

added by: jerome date: 08-10-11

 great php scipt it help me a lot, i will be waiting for your next lessons, keep the PHP script coming 




the latest articles:
• Check if user like page facebook online tool
• base64 decode online free tool javascript
• base64 encode online free tool using javascript
• array slice php funtion
• How to tell google to not change your page title with DMOZ title
• MD5 hash generator Online tools Windows Linux C Php
• Remove duplicates in html lines online javascript
• documentgetElementById()innerHTML javascript set Example
• How to block processes from starting and running in Windows XP
• List of us american presidents with pictures
distancia entre moambique sfrica do sul zimbabwe
how to delete undeletable files in windows xp
how to remove width attribute from an img image with javascript
how to create a autonomous robot witch is able to get his own power from a source
how old is lionel richie
how old is jade foret

 

eXTReMe Tracker