468,469 Members | 1,544 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,469 developers. It's quick & easy.

<OL type="1"> and IE

Hi

In a css page I have the following:

[CSS]
..OLC{float:left; width:150px;text-align:center; }
OL{ list-style-position:inside;}
LI{ height:160px;}

[/CSS]

and in the site page:

[HTML]

....
<div class="OLC">
<OL type="1" start="1">
<LI><br><a href="an_image"><img src="thumbnail_img"></a><br><a
href="some_page.html">page_title</a></li>
.....
</OL>
</div>
<div class="OLC">
......same as above
</div>
[/HTML]

I want to have columns of thumbnails numbered and horizontally
aligned.
Well, it works right in FF and OP but not in IE6-7.

Instead of:
number
image
link-name

it gives:
image
link-name
1


If I remove "height:160px" for LI, it works but I lose the horiz
alignment.

What to do to have IE work properly ??

Thanks

Apr 26 '07 #1
3 4411
Scripsit Bill:
In a css page I have the following:
Why don't you post the URL?
<div class="OLC">
<OL type="1" start="1">
<LI><br><a href="an_image"><img src="thumbnail_img"></a><br><a
href="some_page.html">page_title</a></li>
....
</OL>
Why are you using the apparently redundant div element? Why are you using
invalid markup (img with no alt)? Why do you think (in the markup and in the
heading, but not in the text your message) that type="1" (the default) is
essential here? Why are you using <br(and not CSS) apparantly to create
vertical spacing at the start of a list item?
I want to have columns of thumbnails numbered and horizontally
aligned.
What do you mean by "horizontally aligned"? Do you want to use a table but
refrain from doing so?
If I remove "height:160px" for LI, it works but I lose the horiz
alignment.
I have a feeling that the height of your images might matter too. But you
gave no URL.

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

Apr 27 '07 #2
Hi
Why don't you post the URL?
because it's not on an intranet.
>
<div class="OLC">
<OL type="1" start="1">
<LI><br><a href="an_image"><img src="thumbnail_img"></a><br><a
href="some_page.html">page_title</a></li>
....
</OL>

Why are you using the apparently redundant div element? Why are you using
It was there because at first it was used to enclose other objects too
which were later removed but the div stayed. But it doen't make any
difference for the OL.

invalid markup (img with no alt)? Why do you think (in the markup and in the
The image is self explanatory.
heading, but not in the text your message) that type="1" (the default) is
essential here? Why are you using <br(and not CSS) apparantly to create
vertical spacing at the start of a list item?
To have the index, the image and the link superposed.

I have a feeling that the height of your images might matter too. But you
You're right, I fixed the height of the images and added
overflow:hidden, removed the height property from LI and it worked.

Thanks Jukka

Apr 28 '07 #3
Scripsit Bill:
>Why don't you post the URL?
because it's not on an intranet.
Really? Why would that matter? What matters is that you post a URL pointing
to a document on the Internet, the World Wide Web, also called "www". (Did
you notice it in the name of this group?)
>Why are you using the apparently redundant div element? Why are you
using

It was there because at first it was used to enclose other objects too
which were later removed but the div stayed. But it doen't make any
difference for the OL.
When trying to debug something, the first step should be to remove redundant
complexities. Then you could start removing complexities that you actually
need, in order to see which of them triggers the problem.
>invalid markup (img with no alt)? Why do you think (in the markup
and in the

The image is self explanatory.
To a person who does not see it? Do you have any idea of why alt attributes
are needed?
>heading, but not in the text your message) that type="1" (the
default) is essential here? Why are you using <br(and not CSS)
apparantly to create vertical spacing at the start of a list item?

To have the index, the image and the link superposed.
Try re-reading my question, paying attention to the "and not CSS" part.
Using <bris a coarse and unreliable way of affecting vertical spacing -
and we _are_ in a CSS group.
You're right, I fixed the height of the images and added
overflow:hidden, removed the height property from LI and it worked.
Too bad we cannot see whether you really fixed a problem or created a new
one.

--
Jukka K. Korpela ("Yucca")
http://www.cs.tut.fi/~jkorpela/

Apr 28 '07 #4

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

5 posts views Thread by Eric A. Forgy | last post: by
reply views Thread by NPC403 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.