xxxxxxxxxx
$imagePath = 'path/to/your/image.jpg'; // Replace with your image file path
// Get the size of the image
$imageSize = getimagesize($imagePath);
// Display the dimensions
echo "Image width: " . $imageSize[0] . "px<br>";
echo "Image height: " . $imageSize[1] . "px";
xxxxxxxxxx
$image_size = $_FILES["inputfilename"]["size"];
/*Not From Form*/
$img_size = getimagesize("imagepath"); // returns an array that is filled with info
print_r($img_size);