File2
By: Xmoo | Date: May 13 2009 13:09 | Format: PHP | Expires: never | Size: 3.13 KB | Hits: 1145
- <?php
- $user = $_SESSION['username'];
- $location = "files/".$user."/";
- echo "<font class='kop'>File Upload</font><br><br>";
- {
- if($_FILES['upload']['size']>64000)
- {
- echo "<img src='images/pointers/delete.png' alt='ERROR' border='0'> <b>File to BIG! (Max 500kb allowed)</b>";
- exit;
- }
- {
- echo "<img src='images/pointers/delete.png' alt='ERROR' border='0'> <b>Wrong extension! (JPG, GIF & PNG allowed!)</b>";
- exit;
- }
- $location.$_FILES['upload']['name']))
- {
- echo"<img src='images/pointers/delete.png' alt='ERROR' border='0'> <b>File could not move!</b>";
- exit;
- }
- echo "<br><img src='images/pointers/view.png' alt='SUCCES' border='0'> <b>The File: <a href='http://www.xmoo.org/mytrainer/files/".$user."/".$_FILES['upload']['name']."' target='_blank'>".$_FILES['upload']['name']."</a> Has Been Uploaded!</b>
- <br><br><br>
- <b>URL:</b><br>
- <input type='text' name='url' size='59' onclick='javascript:url.focus();url.select();' value='http://www.xmoo.org/mytrainer/files/".$user."/".$_FILES['upload']['name']."'' READONLY/>
- <br><br>
- <b>Link:</b><br>
- <textarea name='textarea' onclick='javascript:textarea.focus();textarea.select();' cols='45' rows='4' READONLY>
- [url]http://www.xmoo.org/mytrainer/files/".$user."/".$_FILES['upload']['name']."[/url]</textarea>
- <br><br>
- <b>Link with title:</b><br>
- <textarea name='textarea' onclick='javascript:textarea.focus();textarea.select();' cols='45' rows='4' READONLY>
- [url=http://www.xmoo.org/mytrainer/files/".$user."/".$_FILES['upload']['name']."]".$_FILES['upload']['name']."[/url]</textarea>
- <br><br>
- <b>Image:</b><br>
- <textarea name='textarea' onclick='javascript:textarea.focus();textarea.select();' cols='45' rows='4' READONLY>
- [img]http://www.xmoo.org/mytrainer/files/".$user."/".$_FILES['upload']['name']."[/img]</textarea>
- <br><br>
- <b>Thumbnail:</b><br>
- <textarea name='textarea' onclick='javascript:textarea.focus();textarea.select();' cols='45' rows='4' READONLY>
- [thumb]http://www.xmoo.org/mytrainer/files/".$user."/".$_FILES['upload']['name']."[/thumb]</textarea>
- <br><br>
- <b>Image link:</b><br>
- <textarea name='textarea' onclick='javascript:textarea.focus();textarea.select();' cols='45' rows='4' READONLY>
- [link]http://www.xmoo.org/mytrainer/files/".$user."/".$_FILES['upload']['name']."[/link]</textarea>";
- } else {
- echo "<img src='images/pointers/delete.png' alt='ERROR' border='0'> <b>The Upload has failed!</b>"; }
- } else {
- echo '<center><form method="post" action="" enctype="multipart/form-data">
- <b>File:</b> <input type="file" name="upload" size="50" /><br/> <br/>
- <input type="submit" name="submit" value="Upload!" /></form></center>';
- }
- ?>
Latest pastes
1 days ago
2 days ago
5 days ago
6 days ago
6 days ago