inline list separators

J

Jonathan N. Little

dorayme wrote:
Yes, thanks, I had a look at this. I take it the idea "unsnipped"
above is the crucial point of your code. Does not work in IE Mac
either... but that is easily provided for. I could not see
(across the different browsers) a lot of difference in separator
height "improvement" over my footer2 css. It was interesting also
to see how different browsers rendered yours in respect to where
the text was vis a vis the height of the separators. Sometimes in
the middle (most pleasant):

text | text

And sometimes both text and separators on the floor of a
horizontal line:

1
text 1 text

(you will have to imagine the two 1s joined and as a line)

#footer LI + LI:before { content: " :: "; }

looks pretty cool, or even

#footer LI + LI:before { content: " - "; }
 
B

BootNic

dorayme said:
news: (e-mail address removed)
news: (e-mail address removed)
[snip]

[snip]

Make sure you change #nav to #footer2 ;-)

er yes... of course! (thanks)

OK. So now is it ok in IE7?[/QUOTE]

Not onload, that is not at 100%, above or below works great. Appears
to be a line-height issue from here. Change it to 1.2 or more looks fine
on IE 7, look ok on IE 5.5 - IE 6 winxp, line-height seems to be ignored.

The following works in IE 5.01 - IE 7, FF 2.0, SeaMonkey 1.0.5 and
Opera 9.02 on winxp sp2.

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">

<html>
<head>
<meta http-equiv="content-type" content=
"text/html; charset=windows-1252">
<link rel="stylesheet" href="default.css" type="text/css">

<title></title>
<style type="text/css">
body {
background: #8D8FB5;
color: #333;
line-height: 1.3;
margin: 0;
padding: 0;
}
#footer {
background: #8D8FB5;
color: #FFF;
margin-bottom: 1em;
margin-left: auto;
margin-right: auto;
margin-top: 1em;
padding: 0px;
text-align: center;
}
#footer a, #footer2 a {
background: #8D8FB5;
color: #FFF;
font-size: .85em;
text-decoration: none;
}
#footer a:visited, #footer2 a:visited {
background: #8D8FB5;
color: #FFF;
font-size: .85em;
}
#footer a:hover, #footer2 a:hover {
background: #8D8FB5;
color: #F00;
font-size: .85em;
}
#footer a:active, #footer2 a:active {
background: #8D8FB5;
color: #0C0;
font-size: .85em;
}

</style>
<style type="text/css">
#footer2,#footer2 li, #footer2 li a {
list-style: none;
text-align:center;
margin: 0;
padding:0;
background: #8D8FB5;
color: #FFF;
}
#footer2 li {
display: inline;
line-height: 1.2;
}
#footer2 li + li:before {
content: "\00A0\007c\00A0";
}

</style>
<!--[if gte IE 5]>
<style type="text/css">
#footer2 li.firstListItem a {
border-left:none;
}
#footer2 li a {
border-left:0.09em solid #fff; /* if no JS use border */
border:expression('none'); /* remove border with JS */
line-height: 1; /* if no JS set line-height */
line-height:expression(''); /* set to auto with JS */
padding:0 0.5em 0 0.5em; /* if no JS add padding */
padding-left:expression('auto'); /* remove padding with JS */
}
#footer2 {
behavior:url(libefore.htc);
}
#footer2, #footer2 li {
zoom:1; /* set zoom for IE7, tis safe for other IE versions */
}
</style>
<![endif]-->

<style type="text/css">
span.c1 {font-size: .8em}
</style>
</head>

<body>
<div id="footer">
<a href="http://www.y.com.au">website design</a> <span class=
"c1">|</span> <a class="emailTo" href="mailto:[email protected]"
title="...opens email message to contact us">email us</a> |
<a href="http://www.x.com.au/offices/offices.html" title=
"...phone numbers, addresses">contacts</a> | <a href=
"http://www.x.com.au/stockists/sunStockists.html" title="...all
our stockists">stockists</a> | <a href=
"http://www.x.com.au/termsOfTrade.html" title="...legal
document">terms of trade</a>
</div>

<ul id="footer2">
<li class="firstListItem"><a href="http://www.y.com.au">website
design</a></li>

<li><a class="emailTo" href="mailto:[email protected]" title=
"...opens email message to contact us">email us</a></li>

<li><a href="http://www.x.com.au/offices/offices.html" title=
"...phone numbers, addresses">contacts</a></li>

<li><a href="http://www.x.com.au/stockists/sunStockists.html"
title="...all our stockists">stockists</a></li>

<li><a href="http://www.x.com.au/termsOfTrade.html" title=
"...legal document">terms of trade</a></li>
</ul>
<!-- libefore.htc content below
<public:component>
<script type="text/javascript">
var li=element.getElementsByTagName('li');
var liX=li.length;
var liY;
for (var i=1; i<liX; i++) {
liY=li;
// insert | before li firstChild
liY.insertBefore(document.createTextNode('|'),liY.childNodes[0]);
}

</script>
</public:component>
-->
</body>
</html>

--
BootNic Monday, November 06, 2006 9:01 PM

"No man's life, liberty, or property is safe while the legislature is
in session."
*Judge Gideon J. Tucker, 1866.*
 
D

dorayme

"Jonathan N. Little said:
dorayme wrote:


#footer LI + LI:before { content: " :: "; }

looks pretty cool, or even

#footer LI + LI:before { content: " - "; }

Yes, good idea... no need to be fixated on the "|" and
considering the problems it has generated perhaps "::" is a way
to go. But what am I going to talk about if I go this way? Do you
realise how painful it is for a martian not to be in a state of
fretful indecision? "::" is highly unlikely to generate the least
uncertainty... <g>
 
B

BootNic

BootNic said:
news: [email protected] [snip]
#footer2 li a {
border-left:0.09em solid #fff; /* if no JS use border */
border:expression('none'); /* remove border with JS */
line-height: 1; /* if no JS set line-height */
line-height:expression(''); /* set to auto with JS */
padding:0 0.5em 0 0.5em; /* if no JS add padding */
padding-left:expression('auto'); /* remove padding with JS */
height:0; /* IE 5.01 for border without JS */
height:expression('auto');

[snip]

--
BootNic Monday, November 06, 2006 10:38 PM

All my humor is based upon destruction and despair. If the whole
world was tranquil, without disease and violence, I'd be standing on
the breadline right in back of J. Edgar Hoover.
*Lenny Bruce US comedian, satirist, author*
 
J

Jonathan N. Little

BootNic said:
news: [email protected] [snip]
#footer2 li a {
border-left:0.09em solid #fff; /* if no JS use border */
border:expression('none'); /* remove border with JS */
line-height: 1; /* if no JS set line-height */
line-height:expression(''); /* set to auto with JS */
padding:0 0.5em 0 0.5em; /* if no JS add padding */
padding-left:expression('auto'); /* remove padding with JS */
height:0; /* IE 5.01 for border without JS */
height:expression('auto');

[snip]

Sure demonstrates what a PITA IE can be!
 
B

Ben C

There is something I better look into and that is borders not on
the li items but the links themselves?

I think it would work out much the same, as the links are as far as CSS
is concerned more inline boxes (nested inside the inline boxes for the
<li>s), and the height you get for all inline boxes is
based on font size but browser-dependent.
 
D

dorayme

"Jonathan N. Little said:
BootNic said:
news: [email protected] [snip]
#footer2 li a {
border-left:0.09em solid #fff; /* if no JS use border */
border:expression('none'); /* remove border with JS */
line-height: 1; /* if no JS set line-height */
line-height:expression(''); /* set to auto with JS */
padding:0 0.5em 0 0.5em; /* if no JS add padding */
padding-left:expression('auto'); /* remove padding with JS */
height:0; /* IE 5.01 for border without JS */
height:expression('auto');

[snip]

Sure demonstrates what a PITA IE can be!

I was impressed by BN's skills (thanks BN for going to trouble),
and assume it works for the zoom problem that I cannot see. I
notice it fails Mac IE (only the words "terms of trade" appear
(very roughly in the right place but preceded by nothing else in
the list!).

Not greatly tempted though for the simple reason that it looks to
me to be very tactical or else too tricky to troubleshoot and
adapt to different situations.

This zoom business is a bit of a worry eh?

Anyway, I gathered the suggestions into the latest:

http://members.optushome.com.au/droovies/test/footer.html

(Ben C said something that made me mess about with styling in the
first example... so thanks Ben for the trigger)
 
B

BootNic

dorayme said:
news: (e-mail address removed)
Jonathan N. Little said:
BootNic said:
[email protected]
[snip]
#footer2 li a {
border-left:0.09em solid #fff; /* if no JS use border */

Can't see a white border on a white background, change the above
#fff to any other color.
[snip]
I was impressed by BN's skills (thanks BN for going to trouble),
and assume it works for the zoom problem that I cannot see. I
notice it fails Mac IE (only the words "terms of trade" appear
(very roughly in the right place but preceded by nothing else in
the list!).


I have never written anything to work in a mac, but perhaps it would
be acceptable to limit the IE comment to IE 6 and remove the
references to IE 5.
Not greatly tempted though for the simple reason that it looks to
me to be very tactical or else too tricky to troubleshoot and
adapt to different situations.

This zoom business is a bit of a worry eh?


No worries.


[snip]

The libefore.htc seems to be missing, it's needed for my little hacked
up mess to work. The content of the libefore.htc is the other post.

Looks like the first example would be the easy way to go with no
worries unless someone insist the list be a list.
 
D

dorayme

"BootNic said:
Can't see a white border on a white background, change the above
#fff to any other color.
[snip]
I was impressed by BN's skills (thanks BN for going to trouble),
and assume it works for the zoom problem that I cannot see. I
notice it fails Mac IE (only the words "terms of trade" appear
(very roughly in the right place but preceded by nothing else in
the list!).


I have never written anything to work in a mac, but perhaps it would
be acceptable to limit the IE comment to IE 6 and remove the
references to IE 5.
Not greatly tempted though for the simple reason that it looks to
me to be very tactical or else too tricky to troubleshoot and
adapt to different situations.

This zoom business is a bit of a worry eh?


No worries.


[snip]

The libefore.htc seems to be missing,


No it _is_ in ... I have your footer named as footerBN (I messed
about as original footer2 was picking up a few styles from above
where it was... getting a bit messy now...
it's needed for my little hacked
up mess to work. The content of the libefore.htc is the other post.

Looks like the first example would be the easy way to go with no
worries unless someone insist the list be a list.

I had yours as written but thought to bring all together in one
page...

What I am going to do is this, lose footerBN and excise you from
the page and make a page just for your stuff as I had tested it
prior. Hang on...

Now go to
http://members.optushome.com.au/droovies/test/footer.html

and see the link to yours.


I copied it as faithfully as I could, including a bit you added
later. If it is not faithful or you have any improvement, say and
I will put it there.
 
B

BootNic

dorayme said:
news: (e-mail address removed)
[snip]
The libefore.htc seems to be missing,


No it _is_ in ... I have your footer named as footerBN (I messed
about as original footer2 was picking up a few styles from above
where it was... getting a bit messy now...

No issues with the edits other then the border and background both
being white.

[snip]
I had yours as written but thought to bring all together in one
page...

What I am going to do is this, lose footerBN and excise you from
the page and make a page just for your stuff as I had tested it
prior. Hang on...

Now go to
http://members.optushome.com.au/droovies/test/footer.html

and see the link to yours.

I copied it as faithfully as I could, including a bit you added
later. If it is not faithful or you have any improvement, say and
I will put it there.

Copied just fine, tis just a communication error :)

So sorry you had to exile it.

libefore.htc is an external file, should be located at:

http://members.optushome.com.au/droovies/test/libefore.htc

the bit that referred to it is:
behavior:url(libefore.htc);


The content of libefore.htc tis the last bit inside an HTML comment
of my example.

copy of libefore.htc can be found at:
http://www.freefileupload.net/file.php?file=files/081106/1162962744/libefore.htc
 
D

dorayme

news: (e-mail address removed)
[snip]
The libefore.htc seems to be missing,


No it _is_ in ... I have your footer named as footerBN (I messed
about as original footer2 was picking up a few styles from above
where it was... getting a bit messy now...

No issues with the edits other then the border and background both
being white.

[snip]
I had yours as written but thought to bring all together in one
page...

What I am going to do is this, lose footerBN and excise you from
the page and make a page just for your stuff as I had tested it
prior. Hang on...

Now go to
http://members.optushome.com.au/droovies/test/footer.html

and see the link to yours.

I copied it as faithfully as I could, including a bit you added
later. If it is not faithful or you have any improvement, say and
I will put it there.

Copied just fine, tis just a communication error :)

So sorry you had to exile it.

libefore.htc is an external file, should be located at:

http://members.optushome.com.au/droovies/test/libefore.htc

the bit that referred to it is:
behavior:url(libefore.htc);


The content of libefore.htc tis the last bit inside an HTML comment
of my example.

copy of libefore.htc can be found at:
http://www.freefileupload.net/file.php?file=files/081106/1162962744/libefore.h
tc[/QUOTE]

ooeee... will maybe sort tomorrow. That presentational footer is
getting more attractive by the day! <g>
 
D

dorayme

news: (e-mail address removed)
[snip]
I had yours as written but thought to bring all together in one
page...

What I am going to do is this, lose footerBN and excise you from
the page and make a page just for your stuff as I had tested it
prior. Hang on...

Now go to
http://members.optushome.com.au/droovies/test/footer.html

and see the link to yours.

I copied it as faithfully as I could, including a bit you added
later. If it is not faithful or you have any improvement, say and
I will put it there.

Copied just fine, tis just a communication error :)

So sorry you had to exile it.[/QUOTE]

It was to simplify and honour you rather than banish you. Having
a separate file called bootNicsRevenge.html is sort of a
promotion said:
libefore.htc is an external file, should be located at:

http://members.optushome.com.au/droovies/test/libefore.htc

the bit that referred to it is:
behavior:url(libefore.htc);


The content of libefore.htc tis the last bit inside an HTML comment
of my example.

copy of libefore.htc can be found at:
http://www.freefileupload.net/file.php?file=files/081106/1162962744/libefore.h
tc

I put it up. It, of course, looks the same to me on Safari etc.
But does it now behave itself re zoom on IE7? Your example is the
second one at
<http://members.optushome.com.au/droovies/test/bootNicsRevenge.htm
l>
 
B

BootNic

dorayme said:
news: (e-mail address removed)
[snip]
I put it up. It, of course, looks the same to me on Safari etc.
But does it now behave itself re zoom on IE7? Your example is the
second one at
<http://members.optushome.com.au/droovies/test/bootNicsRevenge.html>


http://members.optushome.com.au/droovies/test/footer.html

IEZoom-100.png

{IMG]http://files.photojerk.com/BootNic/IEZoom-125.png[/IMG]
IEZoom-150.png


http://members.optushome.com.au/droovies/test/bootNicsRevenge.html
Javascript disabled

IEZoomB-100.png

IEZoomB-125.png

IEZoomB-150.png


http://members.optushome.com.au/droovies/test/bootNicsRevenge.html
Javascript enabled

IEZoomC-100.png

IEZoomC-125.png

IEZoomC-150.png
 
D

dorayme

news: (e-mail address removed)
[snip]
I put it up. It, of course, looks the same to me on Safari etc.
But does it now behave itself re zoom on IE7? Your example is the
second one at
<http://members.optushome.com.au/droovies/test/bootNicsRevenge.html>


http://members.optushome.com.au/droovies/test/footer.html

IEZoom-100.png

{IMG]http://files.photojerk.com/BootNic/IEZoom-125.png[/IMG]
IEZoom-150.png


http://members.optushome.com.au/droovies/test/bootNicsRevenge.html
Javascript disabled

IEZoomB-100.png

IEZoomB-125.png

IEZoomB-150.png


http://members.optushome.com.au/droovies/test/bootNicsRevenge.html
Javascript enabled

IEZoomC-100.png

IEZoomC-125.png

IEZoomC-150.png
[/QUOTE]

IEZoom is first time I have seen what a mess it can make.

IEZoomB looks good. Better than IEZoomC. This is with JS off? Is
there a moral in this? To be rid of the js bits altogether in
your fix? Or have I misunderstood this or have you described off
and on above wrong?
 
B

BootNic

dorayme said:
news: (e-mail address removed) [snip]
IEZoom is first time I have seen what a mess it can make.

IEZoomB looks good. Better than IEZoomC. This is with JS off? Is
there a moral in this? To be rid of the js bits altogether in
your fix? Or have I misunderstood this or have you described off
and on above wrong?

The javascript portion of the mess just adds a "|" somewhat like style
does, it should have been " | ", and removes the border.

In the libefore.htc file:
liY.insertBefore(document.createTextNode('|'),liY.childNodes[0]);
liY.insertBefore(document.createTextNode(' | '),liY.childNodes[0]);

in the conditional comment for some reason I put:
padding-left:expression('auto'); /* remove padding with JS */
should have been:
padding-left:expression('0'); /* remove padding with JS */

The non JS portion of it just uses a border, which would be remove
if JS is enabled with the expressions.

To remove the JS part just delete the expressions and remove the
behavior reference.

--
BootNic Wednesday, November 08, 2006 9:43 PM

Truly great madness cannot be achieved without significant
intelligence.
*Henrik Tikkanen*
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,774
Messages
2,569,596
Members
45,143
Latest member
DewittMill
Top