English Deutsch Français Italiano Español Português 繁體中文 Bahasa Indonesia Tiếng Việt ภาษาไทย
All categories

Why doesn't the following code show the image as 50% of the container size, instead it just stays default size.










This is some text. This is some text. This is some text.This is some text. This is some text. This is some text.This is some text. This is






2006-08-03 18:53:43 · 2 answers · asked by superhighgain 1 in Computers & Internet Programming & Design

2 answers

First of all... what are you testing it in? Because a lot of the older browsers weren't coded to understand all of the now standard CSS.

It won't be 50% of the container unless you state it as a block level element. Images are inline.

There should be a space before the slash in the img tag.

Don't forget to put the height as 50%, otherwise you just get a narrow but tall image.

You can set the image to float right in the css as well.

Hint: Code for Firefox, tweak for IE and Opera.

2006-08-03 19:34:46 · answer #1 · answered by AmandaKerik 5 · 0 0

what is CSS lol

2006-08-03 19:01:13 · answer #2 · answered by Anonymous · 0 0

fedest.com, questions and answers