Solved

Anchor is not clickable, but only in Firefox

Posted on 2006-11-08
3
1,008 Views
Last Modified: 2008-03-04
Hi, I've never experienced this before, and I'm hoping someone can help me.

I have a few nested divs, and on the inner one, where the text is, I've assigned a style to the anchor tag and hover condition... well, it works perfectly in IE and is ignored, and in fact my anchor because not clickable at all, in Firefox!?

If someone can help, I'd be most obliged.  I am sure this must have something to do with the CSS because it only became a problem when I added the styling.  I've moved the definition around between #stretch and #stretchtext to no avail.

CSS code is:

#stretch {
      position: absolute;
      top: 83px;
      left: 0px;
      height: auto;
      overflow: hidden;
      width: 780px;
}

#stretchbg {
      top: 83px;
      margin: 0px auto;
      background-image: URL('images/sub_bg.gif');
      background-repeat: repeat-y;
}

#stretchtext {
      margin-left: 20px;
      margin-right: 20px;
      height: auto;
      border: 1px dotted white;
}

#stretch a, a:visited, a:link {
      text-decoration: none;
}

#stretch a:hover {
      text-decoration: underline;
      color: #2C70B1;
}


webpage code is:

<div id="content">
      <div id="banner"></div>
      <div id="stretch">
            <div id="stretchbg">
                  <div id="stretchtext"><a href="AustinTestimonial.php"><img src="contentimages/Austin.gif" border="0" width="204" height="58" alt=""> Austin Hospital</a>
                        <p><a href="MonashTestimonial.php"><img src="contentimages/Monash.gif" border="0" width="143" height="33" alt=""> Monash Medical Centre</a></p>
                        <p>&nbsp;</p>
                  </div>
            </div>
            <div id="footer"></div>
      </div>
      
</div>

Thanks heaps!
0
Comment
Question by:hmaloney
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 11

Accepted Solution

by:
JohnModig earned 125 total points
ID: 17904872
I've experienced a similar problem before - then the problem was overlapping div's. Make sure no div is on top of (or overlapping) the div containing the anchor. Even though the top div might be empty or transparent - if it is on top of the anchor, then the anchor won't be clickable in Firefox, but will work in IE.

How to look for the problem:
Try assigning a background-color and border to ALL your divs, just to check the layout. Whenever you are sure everything is ok, simply remove the background-color and border. Since I dont have all your CSS its hard for me to locate if this is the problem. It might be the footer div?

John
0
 
LVL 11

Assisted Solution

by:JohnModig
JohnModig earned 125 total points
ID: 17904882
...or the banner div?

Also, another solution to the same problem is that you can try to set the z-index on the div containing the anchor to a value higher than the surrounding divs, like so:

#stretchtext {
     z-index: 10;
}
0
 

Author Comment

by:hmaloney
ID: 17910314
Thanks for both your help.

It's started working again now.  :-S  but at least I know where to look next time it happens.

Cheers,
Heather
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Unordered lists (HTML ul tags) are very handy to create menus of all types, shapes and sizes.  All it takes is a little knowledge of CSS and the possibilities are endless. First off, you should know the general format for menus created using the …
This article discusses four methods for overlaying images in a container on a web page
In this Micro Tutorial users will learn how to embed custom fonts into websites using @font-face in CSS Select a font: Ensure the EULA allows you to use @font-face: Download the font: Get the browser-compatible files you need: Edit your CSS       - Name …
Video by: Mark
This lesson goes over how to construct ordered and unordered lists and how to create hyperlinks.

717 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question