CSS picture code

inkui

New Member
kod i css för att alla bilder på hemsidan visas i en storlek baserad på bredd eller höjd. Bilden ska skalas ner så att den har rätt proportioner fast förminskas... tex alla bilder som läggs in ska ha en ram och vara 200px breda oavsätt höjden och gärna en som gör att bilderna är 200px höga och samma bredd med förståelsen att proportionerna blir fel.

Hey!

This time(!) I'm looking for a CSS code to make every picture on the same site based on width and/or height. The picture(s) are to scale down to have the right proportions. For example every picture which then adds to the site are to have a border and have a width of 200px regardless of height. On the other hand I'd also would love a code that makes the pictures with a height of 200px and with the same width, with the apprehension that the proportions will be wrong.

Thanks,
Richard aka inkui
 

TheWebGuy

New Member
Not sure what you're asking but if you want to make every image a specific width/height, simply create some CSS like this:

img {
width: 200px;
height: auto;
}

OR

img {
height: 200px;
width: auto;
}

As far as I know, there is no way to evenly proportionate the images using CSS. I'd recommend finding someone who knows JavaScript.
 
Top