Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

CSS Forum


You are currently viewing our CSS Forum as a guest. Please register to participate.
Login



Reply
Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
Old 12-08-2007, 01:07 PM Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
empressreborn's Avatar
Skilled Talker

Posts: 59
Name: Jenn
Location: Stonewood, WV
Trades: 0
I am trying to determine why my Suckerfish dropdown menu is not showing up in IE 6.0 or 5.5. (It displays perfectly in IE 7.0, Mozilla, Opera, and Safari.) From what I've gathered, it's supposed to work in IE 6.0 and 5.5. Thus, my confusion. Any assistance would be greatly appreciated.

The site can be seen here:

http://jennmurray.com/WV_Life/index.html

And my CSS for the menu is as follows:

ul {
margin: -5px 0 0 0;
padding: 0;
list-style: none;
position: relative; z-index: 1;
}

li {
float: left;
position: relative;
width: 92px;
border-bottom: 1px solid #91125f;
}

li ul {
display: none;
position: absolute;
top: 1em;
left: 0;
text-align: left;
}

li > ul {
top: auto;
left: auto;
}

ul li a {
display: block;
text-decoration: none;
color: #fff;
padding: 4px;
border: 1px solid #91125f;
border-bottom: 0;
font-size: 12px;
font-family: Arial, sans serif;
background-image: #91125f url(../images/nav.gif) repeat;
}

li:hover ul, li.over ul {
display: block;
margin-top: 0;
margin-left: -48px;
background: #91125f;
}

#nav a:hover {
color: #ffdab9; background: #91125f;
}

.center {
text-align: center;
}

/* Fix IE. Hide from IE Mac \*/
* html ul li {float: left; height: 1%;}
* html ul li a {height: 1%;}
/* End */
__________________

Please login or register to view this content. Registration is FREE


empressreborn is offline
Reply With Quote
View Public Profile Visit empressreborn's homepage!
 
 
Register now for full access!
Old 12-08-2007, 06:28 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
IE 6 and below cannot :hover on anything except links. In order to get suckerfish to work, you need some scripting. Google for "whatever hover", you only need to use the small .htc file and add 1 line to the CSS to make IE work.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 12-09-2007, 10:04 AM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
empressreborn's Avatar
Skilled Talker

Posts: 59
Name: Jenn
Location: Stonewood, WV
Trades: 0
I attached the .htc file to the CSS file, but the result hasn't changed. The menu doesn't show up at all. It's like I never gave the site one.
__________________

Please login or register to view this content. Registration is FREE


empressreborn is offline
Reply With Quote
View Public Profile Visit empressreborn's homepage!
 
Old 12-09-2007, 12:42 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
where did you put the .htc file ? I've found that I have to have it in the root directory of the site in order for it to work properly.

Also, IE 6 and below won't work with descendent selectors, you'll have to change the li > ul.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 12-10-2007, 07:27 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
empressreborn's Avatar
Skilled Talker

Posts: 59
Name: Jenn
Location: Stonewood, WV
Trades: 0
I have the .htc file in the root folder. And the following is my CSS code:

body { behavior: url(csshover.htc); }

I also changed the li > ul. I gave the ul a class name in the XHTML file and changed the CSS coding to:

li ul.fix {
top: auto;
left: auto;
}

Yet the menu still isn't showing up. Am I missing a blatant error here? Or can something else be causing a problem?
empressreborn is offline
Reply With Quote
View Public Profile Visit empressreborn's homepage!
 
Old 12-10-2007, 08:29 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
vangogh's Avatar
Post Impressionist

Posts: 10,688
Name: Steven Bradley
Location: Boulder, Colorado
Trades: 0
Jenn I use suckerfish (or son of suckerfish) on my own site. To get it to work in IE6 and 5.5 I had to first add some javascript

HTML Code:
var sfHover = function(){
    var sfEls = document.getElementById("top-nav").getElementsByTagName("li");
    for (var i=0; i<sfEls.length; i++){
        sfEls[i].onmouseover=function(){this.className+=" sfhover";}
        sfEls[i].onmouseout=function(){this.className=this.className.replace(new RegExp(" sfhover\\b"), "");}
    }
}
if (window.attachEvent) window.attachEvent("onload", sfHover);
The sfHover class is meant to do what :hover does in FF and IE7.

Then in the css anywhere I have something calling :hover I also add .sfHover. For example I have a style set for:

#top-nav li:hover ul, {left: auto ; width:14em; text-align:left}

I added one for #top-nav li.sfhover ul and end up with:

#top-nav li:hover ul, #top-nav li.sfhover ul {left: auto; width:14em; text-align:left}

Anywhere else I have a style set with :hover in it I add the corresponding .sfHover (and link to the javascript above) and the drop down works fine.

I hope that helps
__________________
l Search Engine Friendly Web Design |
Please login or register to view this content. Registration is FREE

l Tips On Marketing, SEO, Design, and Development |
Please login or register to view this content. Registration is FREE

l
Please login or register to view this content. Registration is FREE
|
Please login or register to view this content. Registration is FREE
vangogh is offline
Reply With Quote
View Public Profile Visit vangogh's homepage!
 
Old 12-10-2007, 09:53 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
The htc file should work too, since I just put the son of suckerfish menu on a new site I'm working on and used the HTC file instead of adding additional javascript.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 12-11-2007, 10:59 AM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
empressreborn's Avatar
Skilled Talker

Posts: 59
Name: Jenn
Location: Stonewood, WV
Trades: 0
I tried the javascript, but to no avail. All I keep getting is this:

empressreborn is offline
Reply With Quote
View Public Profile Visit empressreborn's homepage!
 
Old 12-12-2007, 03:03 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
empressreborn's Avatar
Skilled Talker

Posts: 59
Name: Jenn
Location: Stonewood, WV
Trades: 0
Could it be that the "display:none" is not allowing any of these methods to work? Is there a workaround for it?
empressreborn is offline
Reply With Quote
View Public Profile Visit empressreborn's homepage!
 
Old 12-12-2007, 03:57 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
Ok, here's the code I used for my very simple dropdown (only 1 sub-item)
Note the left: -999em on the submenu instead of display:none, this compensates for the display:none accessibility issue.

CSS
Quote:
#nav a{
display: block;
}

#nav li{
float: left;
margin: 0px 2px;
width: 8.5em;
position: relative;

}

#nav li a{
color: #fff;
padding: 0px 0;
display: block;
padding: 4px;
}

#nav a:link{
padding: 3px 2px;

}

#nav a:hover{
color: #0038ac;
background: #fff;
}

#nav li ul.submenu{
list-style: none;
position: absolute;
width: 10em;
left: -999em;
}

#nav li:hover ul.submenu{
left: auto; /* brings back the sub-menu */
margin-left: -4px;
}

#nav li:hover ul.submenu li{
display: block;
}

/* this is actually in my iefixes.css file */
body {
behavior: url(csshover.htc);
}

HTML:
Quote:
<ul id="nav" >
<li><a href="aboutus.htm">About Us</a>
<ul class="submenu"><li><a href="publications.htm">Publications</a></li>
</ul>
</li>
<li><a href="appointments.htm">Appointments</a></li>
</ul>
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 12-12-2007, 04:19 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
empressreborn's Avatar
Skilled Talker

Posts: 59
Name: Jenn
Location: Stonewood, WV
Trades: 0
Quote:
Originally Posted by LadynRed View Post
Ok, here's the code I used for my very simple dropdown (only 1 sub-item)
Note the left: -999em on the submenu instead of display:none, this compensates for the display:none accessibility issue.
I actually checked out the Sons of Suckerfish menu today and tried that trick in addition to the .htc/javascript. But nothing changed.

I'm at the point where (in a separate sheet for 6) I'm rebuilding the menu from ground zero. Because obviously there's something that I'm missing. ... I got the menu to at least appear, but it would help if I had IE6 so I could check the actual dropdowns.

*bangs head against desk*
__________________

Please login or register to view this content. Registration is FREE


empressreborn is offline
Reply With Quote
View Public Profile Visit empressreborn's homepage!
 
Old 12-12-2007, 04:38 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
empressreborn's Avatar
Skilled Talker

Posts: 59
Name: Jenn
Location: Stonewood, WV
Trades: 0
Aha! I found a stand alone download for IE 6 and 5.5! At least now I can fully test what I'm doing!
empressreborn is offline
Reply With Quote
View Public Profile Visit empressreborn's homepage!
 
Old 12-12-2007, 04:45 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
LadynRed's Avatar
Defies a Status

Posts: 10,016
Location: Tennessee
Trades: 0
I have IE6, if you'll post the code or PM me with the files, I can test it for you.
__________________
Web Goddess & Web Standards Evangelist :) - Tables Be Gone !!

Please login or register to view this content. Registration is FREE


Please login or register to view this content. Registration is FREE

LadynRed is offline
Reply With Quote
View Public Profile
 
Old 12-13-2007, 12:35 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
empressreborn's Avatar
Skilled Talker

Posts: 59
Name: Jenn
Location: Stonewood, WV
Trades: 0
Yea!!! I got it to work in IE 6!!! Don't ask me how, but I did.

The only other thing I need to fix is the padding around the search box. (See above picture.) Even in IE 7, it gives extra padding on the bottom (despite the fact I have it set to 0). How can I correct it?
empressreborn is offline
Reply With Quote
View Public Profile Visit empressreborn's homepage!
 
Old 12-13-2007, 01:26 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
wayfarer07's Avatar
Poo on You

Latest Blog Post:
Introducing WowWindow
Posts: 3,985
Name: Abel Mohler
Location: Asheville, North Carolina USA
Trades: 0
could I see the css as you have it now please?
__________________
Join me on
Please login or register to view this content. Registration is FREE
wayfarer07 is offline
Reply With Quote
View Public Profile Visit wayfarer07's homepage!
 
Old 12-13-2007, 01:30 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
empressreborn's Avatar
Skilled Talker

Posts: 59
Name: Jenn
Location: Stonewood, WV
Trades: 0
Quote:
Originally Posted by wayfarer07 View Post
could I see the css as you have it now please?
For the dropdown menu or the search box?
__________________

Please login or register to view this content. Registration is FREE


empressreborn is offline
Reply With Quote
View Public Profile Visit empressreborn's homepage!
 
Old 12-13-2007, 01:58 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
wayfarer07's Avatar
Poo on You

Latest Blog Post:
Introducing WowWindow
Posts: 3,985
Name: Abel Mohler
Location: Asheville, North Carolina USA
Trades: 0
the search box
__________________
Join me on
Please login or register to view this content. Registration is FREE
wayfarer07 is offline
Reply With Quote
View Public Profile Visit wayfarer07's homepage!
 
Old 12-13-2007, 02:03 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
empressreborn's Avatar
Skilled Talker

Posts: 59
Name: Jenn
Location: Stonewood, WV
Trades: 0
Quote:
Originally Posted by wayfarer07 View Post
the search box
This is what I have for it:

#search {
width: 160px;
padding: 5px 2px 5px 3px;
background-color: #ececec;
border: 2px solid #ccc;
}
__________________

Please login or register to view this content. Registration is FREE


empressreborn is offline
Reply With Quote
View Public Profile Visit empressreborn's homepage!
 
Old 12-13-2007, 02:10 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
empressreborn's Avatar
Skilled Talker

Posts: 59
Name: Jenn
Location: Stonewood, WV
Trades: 0
Quote:
Originally Posted by empressreborn View Post
Yea!!! I got it to work in IE 6!!! Don't ask me how, but I did.
Just in case anyone runs into the same issue, here was the culprit (as I went back through the code to determine exactly what made it work):

I found that simply adding a height attribute was the key. Afterwards, naturally, I came across this:

http://www.communitymx.com/content/a...ge=2&cid=c37E0

It says that
Quote:
A very large percentage of IE/Win bugs are triggered by the lack of any stated dimensions on elements that contain nested floats.
This seemed to be one such bug because after giving it a height, IE 6 has no problems with it at all.
empressreborn is offline
Reply With Quote
View Public Profile Visit empressreborn's homepage!
 
Old 12-13-2007, 03:21 PM Re: Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5
wayfarer07's Avatar
Poo on You

Latest Blog Post:
Introducing WowWindow
Posts: 3,985
Name: Abel Mohler
Location: Asheville, North Carolina USA
Trades: 0
yes, a height of 1% is often used.
__________________
Join me on
Please login or register to view this content. Registration is FREE
wayfarer07 is offline
Reply With Quote
View Public Profile Visit wayfarer07's homepage!
 
Reply     « Reply to Suckerfish Dropdowns - Not Appearing in IE 6 or 5.5

Thread Tools Search this Thread
Search this Thread:

Advanced Search

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

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.55242 seconds with 12 queries