Papajo
05-04-2009, 08:32 PM
Hi
This script is used to display image properties and image picture, I want to hide the empty image box that shows on the page before the form is submitted, any suggestions?? Thanks for any help. Joe
Page url: http://www.portal80.org/Search/A_Image.php
<body bgcolor='#ffffff'>
echo "<center><form name='src' action='' method='post'>
<font color='black'><b>URL:</b></font>
<input type='text' size='55' name='url' value='' />
<input type='submit' name='submit' value='Process It' style='background-color:#000; color: #ffffff;'>
<input type='reset' value='Clear' style='background-color:#000; color: #ffffff;'>
</form></center>";
error_reporting(0);
$url = $_REQUEST[url];
$contents = file("$url");
for($i=0; $i<count($contents); $i++)
$string .= $contents[$i];
list($width,$height) = getimagesize($url);
echo '<br /><b>Filename: ' . $url . '</b><hr>';
$filename = "$url";
if (($pos = strrpos($filename, ".")) === FALSE);
else {
$extension = substr($filename, $pos + 1);
}
echo '<b>Width: '.$width.'<br> ';
echo '<b>Height: '.$height.'<br> ';
echo '<b>Extension: '.$extension.'<br> ';
echo '<b>Filesize: ';
echo strlen($string);
echo '<p><center><img src='.$url.'></center>';
This script is used to display image properties and image picture, I want to hide the empty image box that shows on the page before the form is submitted, any suggestions?? Thanks for any help. Joe
Page url: http://www.portal80.org/Search/A_Image.php
<body bgcolor='#ffffff'>
echo "<center><form name='src' action='' method='post'>
<font color='black'><b>URL:</b></font>
<input type='text' size='55' name='url' value='' />
<input type='submit' name='submit' value='Process It' style='background-color:#000; color: #ffffff;'>
<input type='reset' value='Clear' style='background-color:#000; color: #ffffff;'>
</form></center>";
error_reporting(0);
$url = $_REQUEST[url];
$contents = file("$url");
for($i=0; $i<count($contents); $i++)
$string .= $contents[$i];
list($width,$height) = getimagesize($url);
echo '<br /><b>Filename: ' . $url . '</b><hr>';
$filename = "$url";
if (($pos = strrpos($filename, ".")) === FALSE);
else {
$extension = substr($filename, $pos + 1);
}
echo '<b>Width: '.$width.'<br> ';
echo '<b>Height: '.$height.'<br> ';
echo '<b>Extension: '.$extension.'<br> ';
echo '<b>Filesize: ';
echo strlen($string);
echo '<p><center><img src='.$url.'></center>';