New upload functionality.
git-svn-id: http://svn.automattic.com/wordpress/trunk@831 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
a157baa95c
commit
a87acdf1e2
|
@ -47,4 +47,91 @@ function wp_dropdown_cats($currentcat, $currentparent = 0, $parent = 0, $level =
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
function wp_create_thumbnail($file, $max_side, $effect = '') {
|
||||||
|
|
||||||
|
// 1 = GIF, 2 = JPEG, 3 = PNG
|
||||||
|
|
||||||
|
if(file_exists($file)) {
|
||||||
|
$type = getimagesize($file);
|
||||||
|
|
||||||
|
// if the associated function doesn't exist - then it's not
|
||||||
|
// handle. duh. i hope.
|
||||||
|
|
||||||
|
if(!function_exists('imagegif') && $type[2] == 1) {
|
||||||
|
$error = 'Filetype not supported. Thumbnail not created.';
|
||||||
|
}elseif(!function_exists('imagejpeg') && $type[2] == 2) {
|
||||||
|
$error = 'Filetype not supported. Thumbnail not created.';
|
||||||
|
}elseif(!function_exists('imagepng') && $type[2] == 3) {
|
||||||
|
$error = 'Filetype not supported. Thumbnail not created.';
|
||||||
|
} else {
|
||||||
|
|
||||||
|
// create the initial copy from the original file
|
||||||
|
if($type[2] == 1) {
|
||||||
|
$image = imagecreatefromgif($file);
|
||||||
|
} elseif($type[2] == 2) {
|
||||||
|
$image = imagecreatefromjpeg($file);
|
||||||
|
} elseif($type[2] == 3) {
|
||||||
|
$image = imagecreatefrompng($file);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (function_exists('imageantialias'))
|
||||||
|
imageantialias($image, TRUE);
|
||||||
|
|
||||||
|
$image_attr = getimagesize($file);
|
||||||
|
|
||||||
|
// figure out the longest side
|
||||||
|
|
||||||
|
if($image_attr[0] > $image_attr[1]) {
|
||||||
|
$image_width = $image_attr[0];
|
||||||
|
$image_height = $image_attr[1];
|
||||||
|
$image_new_width = $max_side;
|
||||||
|
|
||||||
|
$image_ratio = $image_width/$image_new_width;
|
||||||
|
$image_new_height = $image_height/$image_ratio;
|
||||||
|
//width is > height
|
||||||
|
} else {
|
||||||
|
$image_width = $image_attr[0];
|
||||||
|
$image_height = $image_attr[1];
|
||||||
|
$image_new_height = $max_side;
|
||||||
|
|
||||||
|
$image_ratio = $image_height/$image_new_height;
|
||||||
|
$image_new_width = $image_width/$image_ratio;
|
||||||
|
//height > width
|
||||||
|
}
|
||||||
|
|
||||||
|
$thumbnail = imagecreatetruecolor($image_new_width, $image_new_height);
|
||||||
|
@imagecopyresized($thumbnail, $image, 0, 0, 0, 0, $image_new_width, $image_new_height, $image_attr[0], $image_attr[1]);
|
||||||
|
|
||||||
|
// move the thumbnail to it's final destination
|
||||||
|
|
||||||
|
$path = explode('/', $file);
|
||||||
|
$thumbpath = substr($file, 0, strrpos($file, '/')) . '/thumb-' . $path[count($path)-1];
|
||||||
|
|
||||||
|
if($type[2] == 1) {
|
||||||
|
if(!imagegif($thumbnail, $thumbpath)) {
|
||||||
|
$error = "Thumbnail path invalid";
|
||||||
|
}
|
||||||
|
} elseif($type[2] == 2) {
|
||||||
|
if(!imagejpeg($thumbnail, $thumbpath)) {
|
||||||
|
$error = "Thumbnail path invalid";
|
||||||
|
}
|
||||||
|
} elseif($type[2] == 3) {
|
||||||
|
if(!imagepng($thumbnail, $thumbpath)) {
|
||||||
|
$error = "Thumbnail path invalid";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if(!empty($error))
|
||||||
|
{
|
||||||
|
return $error;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
?>
|
?>
|
|
@ -78,14 +78,6 @@ setTimeout("redirect();", 600);
|
||||||
<script language="javascript" type="text/javascript">
|
<script language="javascript" type="text/javascript">
|
||||||
//<![CDATA[
|
//<![CDATA[
|
||||||
|
|
||||||
function profile(userID) {
|
|
||||||
window.open ("profile.php?action=viewprofile&user="+userID, "Profile", "width=500, height=450, location=0, menubar=0, resizable=0, scrollbars=1, status=1, titlebar=0, toolbar=0, screenX=60, left=60, screenY=60, top=60");
|
|
||||||
}
|
|
||||||
|
|
||||||
function launchupload() {
|
|
||||||
window.open ("upload.php", "wpupload", "width=380,height=360,location=0,menubar=0,resizable=1,scrollbars=yes,status=1,toolbar=0");
|
|
||||||
}
|
|
||||||
|
|
||||||
function helpWindow(url) {
|
function helpWindow(url) {
|
||||||
window.open(url, "Help", "width=640, height=450, location=0, menubar=0, resizable=0, scrollbars=1, status=1, titlebar=0, toolbar=0, screenX=60, left=60, screenY=60, top=60");
|
window.open(url, "Help", "width=640, height=450, location=0, menubar=0, resizable=0, scrollbars=1, status=1, titlebar=0, toolbar=0, screenX=60, left=60, screenY=60, top=60");
|
||||||
}
|
}
|
||||||
|
@ -145,10 +137,13 @@ window.onload = blurry;
|
||||||
</script>
|
</script>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
<h1 id="wphead"><a href="http://wordpress.org" rel="external" title="Visit WordPress.org">WordPress</a></h1>
|
||||||
<?php
|
<?php
|
||||||
if ($profile==0) {
|
if ($profile==0) {
|
||||||
include('menu.php');
|
include('menu.php');
|
||||||
}
|
}
|
||||||
}
|
?>
|
||||||
|
<h2><?php echo $title; ?></h2>
|
||||||
|
<?php
|
||||||
|
} // endif not standalone
|
||||||
?>
|
?>
|
|
@ -153,14 +153,6 @@ if ($action != 'editcomment') {
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<?php
|
<?php
|
||||||
if ($action != 'editcomment') {
|
|
||||||
if ( ($use_fileupload) && ($user_level >= $fileupload_minlevel)
|
|
||||||
&& (in_array($user_login, $allowed_users) || (trim($fileupload_allowedusers)=="")) ) { ?>
|
|
||||||
<p><input type="button" value="Upload a file or image" onclick="launchupload();" tabindex="10" /></p>
|
|
||||||
<?php }
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
// if the level is 5+, allow user to edit the timestamp - not on 'new post' screen though
|
// if the level is 5+, allow user to edit the timestamp - not on 'new post' screen though
|
||||||
// if (($user_level > 4) && ($action != "post"))
|
// if (($user_level > 4) && ($action != "post"))
|
||||||
|
|
|
@ -119,11 +119,7 @@ edCanvas = document.getElementById('content');
|
||||||
} ?>
|
} ?>
|
||||||
<input name="referredby" type="hidden" id="referredby" value="<?php echo $HTTP_SERVER_VARS['HTTP_REFERER']; ?>" />
|
<input name="referredby" type="hidden" id="referredby" value="<?php echo $HTTP_SERVER_VARS['HTTP_REFERER']; ?>" />
|
||||||
</p>
|
</p>
|
||||||
<?php
|
|
||||||
if ( ($use_fileupload) && ($user_level >= $fileupload_minlevel)
|
|
||||||
&& (in_array($user_login, $allowed_users) || (trim($fileupload_allowedusers)=="")) ) { ?>
|
|
||||||
<p><input type="button" value="Upload a file or image" onclick="launchupload();" tabindex="10" /></p>
|
|
||||||
<?php } ?>
|
|
||||||
</div>
|
</div>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,3 @@
|
||||||
<h1 id="wphead"><a href="http://wordpress.org" rel="external">WordPress</a></h1>
|
|
||||||
|
|
||||||
<ul id="adminmenu">
|
<ul id="adminmenu">
|
||||||
<?php
|
<?php
|
||||||
|
@ -13,13 +12,15 @@ foreach ($menu as $item) {
|
||||||
// 0 = user level, 1 = file, 2 = name
|
// 0 = user level, 1 = file, 2 = name
|
||||||
$self = str_replace('/wp-admin/', '', $PHP_SELF);
|
$self = str_replace('/wp-admin/', '', $PHP_SELF);
|
||||||
if ((substr($self, -20) == substr($item[1], -20)) || ($parent_file && ($item[1] == $parent_file))) $class = ' class="current"';
|
if ((substr($self, -20) == substr($item[1], -20)) || ($parent_file && ($item[1] == $parent_file))) $class = ' class="current"';
|
||||||
if ($user_level >= $item[0]) echo "\n\t<li><a href='{$item[1]}'$class>{$item[2]}</a></li>";
|
if ($user_level >= $item[0]) {
|
||||||
|
if (('upload.php' == $item[1] && $use_fileupload && ($user_level >= $fileupload_minlevel)
|
||||||
|
&& (in_array($user_login, explode(' ', $allowed_users)) || (trim($fileupload_allowedusers)==""))) || 'upload.php' != $item[1])
|
||||||
|
echo "\n\t<li><a href='{$item[1]}'$class>{$item[2]}</a></li>";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
?>
|
?>
|
||||||
<li><a href="<?php echo "$siteurl/$blogfilename"; ?>">View site</a></li>
|
<li><a href="<?php echo "$siteurl/$blogfilename"; ?>" title="View your site">View site</a></li>
|
||||||
<li class="last"><a href="<?php echo $siteurl ?>/wp-login.php?action=logout">Logout (<?php echo stripslashes($user_nickname) ?>)</a></li>
|
<li class="last"><a href="<?php echo $siteurl ?>/wp-login.php?action=logout" title="Logout of this account">Logout (<?php echo stripslashes($user_nickname) ?>)</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
<h2><?php echo $title; ?></h2>
|
|
|
@ -5,6 +5,7 @@
|
||||||
3 users.php Users
|
3 users.php Users
|
||||||
4 options.php Options
|
4 options.php Options
|
||||||
4 templates.php Templates
|
4 templates.php Templates
|
||||||
|
5 upload.php Upload
|
||||||
0 profile.php My Profile
|
0 profile.php My Profile
|
||||||
***
|
***
|
||||||
(Everything after the '***' is a comment.)
|
(Everything after the '***' is a comment.)
|
||||||
|
|
|
@ -1,8 +1,7 @@
|
||||||
<?php
|
<?php
|
||||||
/* WP File Upload - original hack by shockingbird.com */
|
$title = 'Upload Image or File';
|
||||||
|
|
||||||
$standalone="1";
|
require_once('admin-header.php');
|
||||||
require_once("./admin-header.php");
|
|
||||||
|
|
||||||
if ($user_level == 0) //Checks to see if user has logged in
|
if ($user_level == 0) //Checks to see if user has logged in
|
||||||
die ("Cheatin' uh ?");
|
die ("Cheatin' uh ?");
|
||||||
|
@ -10,110 +9,78 @@ die ("Cheatin' uh ?");
|
||||||
if (!$use_fileupload) //Checks if file upload is enabled in the config
|
if (!$use_fileupload) //Checks if file upload is enabled in the config
|
||||||
die ("The admin disabled this function");
|
die ("The admin disabled this function");
|
||||||
|
|
||||||
$allowed_types = explode(" ", trim($fileupload_allowedtypes));
|
$allowed_types = explode(' ', trim($fileupload_allowedtypes));
|
||||||
|
|
||||||
?><html>
|
if ($HTTP_POST_VARS['submit']) {
|
||||||
<head>
|
$action = 'upload';
|
||||||
<title>WordPress » Upload images/files</title>
|
} else {
|
||||||
<style type="text/css">
|
$action = '';
|
||||||
<!--
|
|
||||||
body {
|
|
||||||
|
|
||||||
margin: 30px;
|
|
||||||
}
|
}
|
||||||
<?php
|
|
||||||
if (!$is_NS4) {
|
if (!is_writable($fileupload_realpath))
|
||||||
|
$action = 'not-writable';
|
||||||
?>
|
?>
|
||||||
textarea,input,select {
|
|
||||||
background-color: white;
|
|
||||||
border-width: 1px;
|
|
||||||
border-color: #cccccc;
|
|
||||||
border-style: solid;
|
|
||||||
padding: 2px;
|
|
||||||
margin: 1px;
|
|
||||||
}
|
|
||||||
<?php if (!$is_gecko) { ?>
|
|
||||||
.checkbox {
|
|
||||||
border-width: 0px;
|
|
||||||
border-color: transparent;
|
|
||||||
border-style: solid;
|
|
||||||
padding: 0px;
|
|
||||||
margin: 0px;
|
|
||||||
}
|
|
||||||
.uploadform {
|
|
||||||
background-color: white;
|
|
||||||
<?php if ($is_winIE) { ?>
|
|
||||||
filter: alpha(opacity:100);
|
|
||||||
<?php } ?>
|
|
||||||
border-width: 1px;
|
|
||||||
border-color: #333333;
|
|
||||||
border-style: solid;
|
|
||||||
padding: 2px;
|
|
||||||
margin: 1px;
|
|
||||||
width: 265px;
|
|
||||||
height: 24px;
|
|
||||||
}
|
|
||||||
<?php } ?>
|
|
||||||
<?php
|
|
||||||
}
|
|
||||||
?>
|
|
||||||
-->
|
|
||||||
</style>
|
|
||||||
<script type="text/javascript">
|
|
||||||
<!-- // idocs.com's popup tutorial rules !
|
|
||||||
function targetopener(blah, closeme, closeonly) {
|
|
||||||
if (! (window.focus && window.opener))return true;
|
|
||||||
window.opener.focus();
|
|
||||||
if (! closeonly)window.opener.document.post.content.value += blah;
|
|
||||||
if (closeme)window.close();
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
//-->
|
|
||||||
</script>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
|
|
||||||
<table align="center" width="100%" height="100%" cellpadding="15" cellspacing="0" border="1" style="border-width: 1px; border-color: #cccccc;">
|
<div class="wrap">
|
||||||
<tbody>
|
|
||||||
<tr>
|
|
||||||
<td valign="top" style="background-color: transparent; <?php if ($is_gecko || $is_macIE) { ?>background-image: url('../wp-images/bgbookmarklet3.gif');<?php } elseif ($is_winIE) { ?>background-color: #cccccc; filter: alpha(opacity:60);<?php } ?>;">
|
|
||||||
<?php
|
|
||||||
|
|
||||||
if (!$HTTP_POST_VARS["submit"]) {
|
<?php
|
||||||
$i = implode(", ", $allowed_types);
|
switch ($action) {
|
||||||
|
case 'not-writable':
|
||||||
?>
|
?>
|
||||||
<p><strong>File upload</strong></p>
|
<p>It doesn't look like you can use the file upload feature at this time because the directory you have specified (<code><?php echo $fileupload_realpath; ?></code>) doesn't appear to be writable by WordPress. Check the permissions on the directory and for typos.</p>
|
||||||
<p>You can upload files of type:<br /><em><?php echo $i ?></em></p>
|
|
||||||
<p>The maximum size of the file should be:<br /><em><?php echo $fileupload_maxk ?> KB</em></p>
|
<?php
|
||||||
|
break;
|
||||||
|
case '':
|
||||||
|
foreach ($allowed_types as $type) {
|
||||||
|
$type_tags[] = "<code>$type</code>";
|
||||||
|
}
|
||||||
|
$i = implode(', ', $type_tags);
|
||||||
|
?>
|
||||||
|
<p>You can upload files with the extension <?php echo $i ?> as long as they are no larger than <?php echo $fileupload_maxk; ?> <abbr title="Kilobytes">KB</abbr>. If you’re an admin your can configure these values under <a href="options.php">options</a>.</p>
|
||||||
<form action="upload.php" method="post" enctype="multipart/form-data">
|
<form action="upload.php" method="post" enctype="multipart/form-data">
|
||||||
|
<p>
|
||||||
|
<label for="img1">File:</label>
|
||||||
|
<br />
|
||||||
<input type="hidden" name="MAX_FILE_SIZE" value="<?php echo $fileupload_maxk * 1024 ?>" />
|
<input type="hidden" name="MAX_FILE_SIZE" value="<?php echo $fileupload_maxk * 1024 ?>" />
|
||||||
<input type="file" name="img1" size="30" class="uploadform" />
|
<input type="file" name="img1" id="img1" size="35" class="uploadform" /></p>
|
||||||
<br /><br />
|
<p>
|
||||||
Description:<br />
|
<label for="imgdesc">Description:</label><br />
|
||||||
<input type="text" name="imgdesc" size="30" class="uploadform" />
|
<input type="text" name="imgdesc" id="imgdesc" size="30" class="uploadform" />
|
||||||
<br /><br />
|
</p>
|
||||||
<input type="submit" name="submit" value="upload !" class="search" />
|
|
||||||
|
<p>Create a thumbnail?</p>
|
||||||
|
<p>
|
||||||
|
<label for="thumbsize_no">
|
||||||
|
<input type="radio" name="thumbsize" value="none" checked="checked" id="thumbsize_no" />
|
||||||
|
No thanks</label>
|
||||||
|
<br />
|
||||||
|
<label for="thumbsize_small">
|
||||||
|
<input type="radio" name="thumbsize" value="small" id="thumbsize_small" />
|
||||||
|
Small (200px largest side)</label>
|
||||||
|
<br />
|
||||||
|
<label for="thumbsize_large">
|
||||||
|
<input type="radio" name="thumbsize" value="large" id="thumbsize_large" />
|
||||||
|
Large (400px largest side)</label>
|
||||||
|
<br />
|
||||||
|
<label for="thumbsize_custom">
|
||||||
|
<input type="radio" name="thumbsize" value="custom" id="thumbsize_custom" />
|
||||||
|
Custom size</label>
|
||||||
|
:
|
||||||
|
<input type="text" name="imgthumbsizecustom" size="4" />
|
||||||
|
px (largest side) </p>
|
||||||
|
<p><input type="submit" name="submit" value="Upload File" /></p>
|
||||||
</form>
|
</form>
|
||||||
</td>
|
</div><?php
|
||||||
</tr>
|
break;
|
||||||
</tbody>
|
case 'upload':
|
||||||
</table>
|
|
||||||
</body>
|
|
||||||
</html><?php die();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<?php //Makes sure they choose a file
|
<?php //Makes sure they choose a file
|
||||||
|
|
||||||
//print_r($HTTP_POST_FILES);
|
//print_r($HTTP_POST_FILES);
|
||||||
//die();
|
//die();
|
||||||
|
|
||||||
if (!empty($HTTP_POST_VARS)) { //$img1_name != "") {
|
|
||||||
|
|
||||||
$imgalt = (isset($HTTP_POST_VARS['imgalt'])) ? $HTTP_POST_VARS['imgalt'] : $imgalt;
|
$imgalt = (isset($HTTP_POST_VARS['imgalt'])) ? $HTTP_POST_VARS['imgalt'] : $imgalt;
|
||||||
|
|
||||||
|
@ -176,18 +143,18 @@ if (!empty($HTTP_POST_VARS)) { //$img1_name != "") {
|
||||||
<input type="hidden" name="img1_name" value="<?php echo $img2_name;?>" />
|
<input type="hidden" name="img1_name" value="<?php echo $img2_name;?>" />
|
||||||
<input type="hidden" name="img1_size" value="<?php echo $img1_size;?>" />
|
<input type="hidden" name="img1_size" value="<?php echo $img1_size;?>" />
|
||||||
<input type="hidden" name="img1" value="<?php echo $pathtofile2;?>" />
|
<input type="hidden" name="img1" value="<?php echo $pathtofile2;?>" />
|
||||||
|
<input type="hidden" name="thumbsize" value="<?php echo $_REQUEST['thumbsize'];?>" />
|
||||||
|
<input type="hidden" name="imgthumbsizecustom" value="<?php echo $_REQUEST['imgthumbsizecustom'];?>" />
|
||||||
Alternate name:<br /><input type="text" name="imgalt" size="30" class="uploadform" value="<?php echo $img2_name;?>" /><br />
|
Alternate name:<br /><input type="text" name="imgalt" size="30" class="uploadform" value="<?php echo $img2_name;?>" /><br />
|
||||||
<br />
|
<br />
|
||||||
Description:<br /><input type="text" name="imgdesc" size="30" class="uploadform" value="<?php echo $imgdesc;?>" />
|
Description:<br /><input type="text" name="imgdesc" size="30" class="uploadform" value="<?php echo $imgdesc;?>" />
|
||||||
<br />
|
<br />
|
||||||
<input type="submit" name="submit" value="confirm !" class="search" />
|
<input type="submit" name="submit" value="Rename" class="search" />
|
||||||
</form>
|
</form>
|
||||||
</td>
|
</div>
|
||||||
</tr>
|
<?php
|
||||||
</tbody>
|
require('admin-footer.php');
|
||||||
</table>
|
die();
|
||||||
</body>
|
|
||||||
</html><?php die();
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -204,12 +171,29 @@ if (!empty($HTTP_POST_VARS)) { //$img1_name != "") {
|
||||||
} else {
|
} else {
|
||||||
@unlink($img1);
|
@unlink($img1);
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
} else {
|
||||||
rename($img1, $pathtofile)
|
rename($img1, $pathtofile)
|
||||||
or die("Couldn't Upload Your File to $pathtofile.");
|
or die("Couldn't Upload Your File to $pathtofile.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if($HTTP_POST_VARS['thumbsize'] != 'none' ) {
|
||||||
|
if($HTTP_POST_VARS['thumbsize'] == 'small') {
|
||||||
|
$max_side = 200;
|
||||||
}
|
}
|
||||||
|
elseif($HTTP_POST_VARS['thumbsize'] == 'large') {
|
||||||
|
$max_side = 400;
|
||||||
|
}
|
||||||
|
elseif($HTTP_POST_VARS['thumbsize'] == 'custom') {
|
||||||
|
$max_side = $HTTP_POST_VARS['imgthumbsizecustom'];
|
||||||
|
}
|
||||||
|
|
||||||
|
$result = wp_create_thumbnail($pathtofile, $max_side, NULL);
|
||||||
|
if($result != 1) {
|
||||||
|
print $result;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
if ( ereg('image/',$img1_type)) {
|
if ( ereg('image/',$img1_type)) {
|
||||||
|
@ -220,35 +204,24 @@ if ( ereg('image/',$img1_type)) {
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|
||||||
<p><strong>File uploaded !</strong></p>
|
<h3>File uploaded!</h3>
|
||||||
<p>Your file <b><?php echo "$img1_name"; ?></b> was uploaded successfully !</p>
|
<p>Your file <code><?php echo $img1_name; ?></code> was uploaded successfully !</p>
|
||||||
<p>Here's the code to display it:</p>
|
<p>Here’s the code to display it:</p>
|
||||||
<p><form>
|
<p><code><?php echo $piece_of_code; ?></code>
|
||||||
<!--<textarea cols="25" rows="3" wrap="virtual"><?php echo "<img src="$fileupload_url/$img1_name" border="0" alt="" />"; ?></textarea>-->
|
|
||||||
<input type="text" name="imgpath" value="<?php echo $piece_of_code; ?>" size="38" style="padding: 5px; margin: 2px;" /><br />
|
|
||||||
<input type="button" name="close" value="Add the code to your post !" class="search" onClick="targetopener('<?php echo $piece_of_code; ?>')" style="margin: 2px;" />
|
|
||||||
</form>
|
|
||||||
</p>
|
</p>
|
||||||
<p><strong>Image Details</strong>: <br />
|
<p><strong>Image Details</strong>: <br />
|
||||||
name:
|
Name:
|
||||||
<?php echo "$img1_name"; ?>
|
<?php echo $img1_name; ?>
|
||||||
<br />
|
<br />
|
||||||
size:
|
Size:
|
||||||
<?php echo round($img1_size/1024,2); ?> KB
|
<?php echo round($img1_size / 1024, 2); ?> <abbr title="Kilobyte">KB</abbr><br />
|
||||||
<br />
|
Type:
|
||||||
type:
|
<?php echo $img1_type; ?>
|
||||||
<?php echo "$img1_type"; ?>
|
|
||||||
</p>
|
</p>
|
||||||
<p align="right">
|
</div>
|
||||||
<form>
|
<p><a href="upload.php">Start over</a>.</p>
|
||||||
<input type="button" name="close" value="Close this window" class="search" onClick="window.close()" />
|
<?php
|
||||||
</form>
|
break;
|
||||||
</p>
|
}
|
||||||
</td>
|
include('admin-footer.php');
|
||||||
</tr>
|
?>
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
|
|
||||||
</body>
|
|
||||||
|
|
||||||
</html>
|
|
Loading…
Reference in New Issue