I have a webpage that displays images that I don’t know their size in advance. I tried to use the GD functions to make the script resize and crop the images from me "Just before they are displayed .. I don't need caches", but I failed. I need a script that I can name as follows
<img src="display.php?src=blablabla&height=100&width=200" ?>
or even calculating the width and height of the css to keep the proportions and make the image by touching the box from the inside, like
<img src="blabla.jpg" style="height:<?php echo $height; ?>; width:<?php echo width; ?>" />
I do not need any caching. How can i do this?
source
share