TinyPortal

Development => Support => Topic started by: spookdude on October 21, 2007, 07:38:08 AM

Title: Front Page Picture Scaling
Post by: spookdude on October 21, 2007, 07:38:08 AM
Hi, quick question.
Is there any way I can get pictures that are in front page articles/posts to scale to the given space? I know I can just downsize the picture to fit, but it won't be the same for every resolution.. Any help is appreciated!
-Spookd
Title: Re: Front Page Picture Scaling
Post by: Nokonium on October 21, 2007, 09:35:55 AM
According to my HTML book "You can use a percentage value on the width attribute for the image tag"

The percentage is of the 'parent' width and not the width of the image, so say if you have a <div> containing an image and text and use 50% for the image the image size will scale to fit 50% of the div

Using an image that doesn't have a finite size will slow down the page loading.