HighDots Forums  

IE & Firefox differences with inline-block styled divs

Cascading Style Sheets Layout/presentation on the WWW (comp.infosystems.www.authoring.stylesheets)


Discuss IE & Firefox differences with inline-block styled divs in the Cascading Style Sheets forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Vic
 
Posts: n/a

Default IE & Firefox differences with inline-block styled divs - 08-16-2004 , 07:14 AM






I suspect that Firefox is doing it right (it usually is) but I worked
out a page thinking this *should* do what I want and lo and behold it
did work in IE6

http://www.fogcat.co.uk/example/test002.html

But when looking at Firefox it goes all odd. If you remove all the
internal "imagediv" div from the "imagechunk" div it nearly works but
doesn't algin the "link text" like IE.

Again my question is... how can I achieve an effect like I've got in
IE6 in a cross browser manner?

Reply With Quote
  #2  
Old   
Spartanicus
 
Posts: n/a

Default Re: IE & Firefox differences with inline-block styled divs - 08-16-2004 , 08:14 AM






redvic0001 (AT) hotmail (DOT) com (Vic) wrote:

Quote:
I suspect that Firefox is doing it right (it usually is) but I worked
out a page thinking this *should* do what I want and lo and behold it
did work in IE6

http://www.fogcat.co.uk/example/test002.html
inline-block is a CSS 2.1 value not supported by Firefox or IE. So it
doesn't "work" in IE, it get's it wrong, you just like what it's doing.

Quote:
Again my question is... how can I achieve an effect like I've got in
IE6 in a cross browser manner?
Again the question is "what are you actually trying to do?", supply
something using real content so that we can provide proper help.

--
Spartanicus


Reply With Quote
  #3  
Old   
Vic
 
Posts: n/a

Default Re: IE & Firefox differences with inline-block styled divs - 08-16-2004 , 02:05 PM



Quote:
Again the question is "what are you actually trying to do?", supply
something using real content so that we can provide proper help.
What I am trying to do is not dissimilar from the IE result.

I want a set of divs down the page (the "imagedivs")
Each div will contain:
* An image - but that image will be nested inside a div - it's
returned
that way from a php function. Images may be of varying height so
I can't
use pixel values at top margins or anything like that.
* A link to another page

- The link should be positioned to the right of the image and
aligned
vertically with the centre of the image.

This is one of those things that's a doddle with tables, but I'm
trying to train myself to think CSS.

+--------------------------------------+
Quote:
+----------------+ |
| .............. | | --- <div
| : : | | ... <img
| : : | Link here |
| : : | |
| .............. | |
+----------------+ |
+--------------------------------------+

+--------------------------------------+
Quote:
+----------------+ |
| .............. | |
| : : | |
| : : | Link here |
| : : | |
| .............. | |
+----------------+ |
+--------------------------------------+


Reply With Quote
  #4  
Old   
Spartanicus
 
Posts: n/a

Default Re: IE & Firefox differences with inline-block styled divs - 08-16-2004 , 05:24 PM



redvic0001 (AT) hotmail (DOT) com (Vic) wrote:

Quote:
Again the question is "what are you actually trying to do?", supply
something using real content so that we can provide proper help.

What I am trying to do is not dissimilar from the IE result.
Sigh, you are again referring to the layout you want without showing
actual content that would allow us to judge the fundamentals.

Quote:
- The link should be positioned to the right of the image and
aligned
vertically with the centre of the image.
img{vertical-align:middle}

<img ...><a href="foobar">foobar</a>

--
Spartanicus


Reply With Quote
  #5  
Old   
Vic
 
Posts: n/a

Default Re: IE & Firefox differences with inline-block styled divs - 08-18-2004 , 01:36 AM



Spartanicus <me (AT) privacy (DOT) net> wrote

....
Quote:
Sigh, you are again referring to the layout you want without showing
actual content that would allow us to judge the fundamentals.
....

<div class='sectionlink'>
<div class='albumimage'>
<div class='thumbnailPicture'>
<a href='./display.php?album_id=411f946359cae'><img
src='./gallery/pictures/411f946359cae/thumbnails/nanci.jpg'
alt='Display the album' width="100" height="149" border='0'></a>
</div>
</div>
<div class='albumlink'>
<a ' href='./display.php?album_id=411f946359cae'>First
Album</a><br />
</div>
</div>
<div class='sectionlink'>
<div class='albumimage'>
<div class='thumbnailPicture'>
<a href='./display.php?album_id=411f93f1c15f4'><img
src='./gallery/pictures/411f93f1c15f4/thumbnails/1s_20and_200s.jpg'
alt='Display the album' width="100" height="149" border='0'></a>
</div>
</div>
<div class='albumlink'>
<a ' href='./display.php?album_id=411f93f1c15f4'>Second
Album</a><br />
</div>
</div>


Reply With Quote
  #6  
Old   
Spartanicus
 
Posts: n/a

Default Re: IE & Firefox differences with inline-block styled divs - 08-18-2004 , 06:46 AM



redvic0001 (AT) hotmail (DOT) com (Vic) wrote:

Quote:
Sigh, you are again referring to the layout you want without showing
actual content that would allow us to judge the fundamentals.
[Div soup snipped]

What we have here is a failure to communicate.

Before you can think about styling the proper structure has to be
applied, structure trumps presentation, content should make sense sans
css, and in the context of this thread: the choice of styling depends on
it.

Content should therefore be marked up according to what it *is*, not how
you want it to look or sound like (with or without css).

The code you posted still fails to show us what type of content it is,
this makes suggesting a styling method a stab in the dark.

<stab in low light conditions>
Linked non square image thumbs of "albums" with a text link next to it:
an index of photo albums perhaps?
</stab in low light conditions>

Div's and span's are a semantically neutral "last resort" type of
markup, they should only be used if there's nothing better available.

Imo there's no single markup element that suites this type of content,
but I wouldn't resort to div's. I'd mark them up as list items if it's
just a thumbnail and a short text link (not a paragraph), in which case
the img{vertical-align:middle} styling I suggested earlier would work to
create the visual appearance you want.

If the thumb images differ in width and the index listing is to be
displayed vertically then a table could be the right type of markup (it
allows the text links to be lined up logically). In the case of table
markup you should use the cell align and valign attributes to create the
visual appearance you want.

--
Spartanicus


Reply With Quote
  #7  
Old   
chiazma
 
Posts: n/a

Default Re: IE & Firefox differences with inline-block styled divs - 08-24-2004 , 01:27 PM




Spartanicus wrote:
Quote:
*redvic0001 (AT) hotmail (DOT) com (Vic) wrote:
[color=darkred]



stab in low light conditions
Linked non square image thumbs of "albums" with a text link next to
it:
an index of photo albums perhaps?
/stab in low light conditions

*
[condescending]Pretending to help people[/condescending]



--
chiazma
------------------------------------------------------------------------
Posted via http://www.forum4designers.com
------------------------------------------------------------------------
View this thread: http://www.forum4designers.com/message108445.html



Reply With Quote
  #8  
Old   
Neal
 
Posts: n/a

Default Re: IE & Firefox differences with inline-block styled divs - 08-26-2004 , 10:52 AM



On Tue, 24 Aug 2004 13:27:25 -0500, chiazma
<chiazma.1blsun (AT) mail (DOT) forum4designers.com> wrote:

Quote:
Spartanicus wrote:
*redvic0001 (AT) hotmail (DOT) com (Vic) wrote:
[color=darkred]
stab in low light conditions
Linked non square image thumbs of "albums" with a text link next to
it:
an index of photo albums perhaps?
/stab in low light conditions

[condescending]Pretending to help people[/condescending]
<serious>Wanting to help those who offer enough info to let us</serious>

Quote:
------------------------------------------------------------------------
Posted via http://www.forum4designers.com
------------------------------------------------------------------------
View this thread: http://www.forum4designers.com/message108445.html
<condescending>Pretewnding to help people</condescending>


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.