Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <form id='login' action='login.php' method='post' accept-charset='UTF-8'>
- <fieldset >
- <legend>Login</legend>
- <input type='hidden' name='submitted' id='submitted' value='1'/>
- <label for='username' >UserName*:</label>
- <input type='text' name='username' id='username' maxlength="10" />
- <label for='password' >Password*:</label>
- <input type='password' name='password' id='password' maxlength="10" />
- <input type='submit' name='Submit' value='Submit' />
- </fieldset>
- </form>
- <?php
- $usr="root";
- $pwd="root";
- $username=$_POST['username'];
- $password=$_POST['password'];
- if(($username==$usr) && ($password==$pwd) )
- {
- header('Location: ./upload.php');
- }
- else
- {
- echo '<br>login unsuccessfull';
- }
- ?>
- $errors = array();
- $uploadedFiles = array();
- $extension = array("jpeg","jpg","png","gif","JPG","JPEG","GIF","PNG");
- $bytes = 1024;
- $KB = 100024;
- $totalBytes = $bytes * $KB;
- $UploadFolder = "./images";
- $counter = 0;
- foreach($_FILES["files"]["tmp_name"] as $key=>$tmp_name) //throws an error
- {
- $temp = $_FILES["files"]["tmp_name"][$key];
- $name = $_FILES["files"]["name"][$key];
- if(empty($temp))
- {
- break;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement