edoplaza Posted November 19, 2009 Report Share Posted November 19, 2009 (edited) Hello, I created a page where I display a picture using the following script: Edited November 19, 2009 by edoplaza Quote Link to comment Share on other sites More sharing options...
falkencreative Posted November 19, 2009 Report Share Posted November 19, 2009 I might start here: http://articles.sitepoint.com/article/image-resizing-php Quote Link to comment Share on other sites More sharing options...
edoplaza Posted November 19, 2009 Author Report Share Posted November 19, 2009 Thanks, I found a simpler way: <?php function scale($url,$width){ $size = GetImageSize($url); $xp = $size[0]/$width; $yp = $size[1]/$xp; echo ''; } scale("images/frontpic.jpg",290); ?> It works! Now, I'd like to draw a little gray rectangle around that picture, with a padding of 4 or 5 pixels , and a 1 pixel black border. Is it possible to do that? Thanks, Eduardo Quote Link to comment Share on other sites More sharing options...
falkencreative Posted November 19, 2009 Report Share Posted November 19, 2009 I'm sure it is possible... I'll require some good web searching, since I'm not sure off the top of my head. Another alternative... a bit easier and you don't have to mess with PHP. Wrap each thumbnail in a div, with a gray background color, 4 or 5 pixel padding on all sides, and the 1px border. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.