16 Filing lecture 3 php

Post on 15-Jan-2015

137 views 4 download

Tags:

description

 

Transcript of 16 Filing lecture 3 php

File Handling

Copyright © 2012 Muhammad Baqar Qazi.

File Uploading

Input Control For File <input type=“file” name=“myfile” />

Form attribute: The enctype attribute specifies how the form-data should be

encoded when submitting it to the server.

Note: The enctype attribute can be used only if method="post".

enctype="multipart/form-data"

File Uploading

First We need to follow some steps in order to do file uploading.

1.Check For Empty File.

2.Directory exist or Not.

3.File exist or not.

4.File size Restriction.

5.File Extension

6.Move uploaded file.

Questions?