1
2<?php
3$size = getimagesize("http://www.example.com/gifs/logo.gif");
4
5// if the file name has space in it, encode it properly
6$size = getimagesize("http://www.example.com/gifs/lo%20go.gif");
7
8?>
9
10
1
2<?php
3list($width, $height, $type, $attr) = getimagesize("img/flag.jpg");
4echo "<img src=\"img/flag.jpg\" $attr alt=\"getimagesize() example\" />";
5?>
6
7