Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8938831
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T10:43:19+00:00 2026-06-15T10:43:19+00:00

I have some simple CSS/HTML for a very basic tooltip: <style type=text/css> .tooltip {

  • 0

I have some simple CSS/HTML for a very basic tooltip:

    <style type="text/css">
    .tooltip {
        text-decoration: none;
        position: relative;
    }
    .tooltip span {
        margin-left: -999em;
        position: absolute;
    }
    .tooltip:hover span {
        border-radius: 5px 5px; -moz-border-radius: 5px; -webkit-border-radius: 5px; 
        box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.1); -webkit-box-shadow: 5px 5px rgba(0, 0, 0, 0.1); -moz-box-shadow: 5px 5px rgba(0, 0, 0, 0.1);
        position: absolute; left: 1em; top: 2em; z-index: 99;
        margin-left: 0; width: 250px;
    }
    .custom { padding: 0.4em 0.4em 0.4em 0.8em; }
    .info { background: #D5F1FF; border: 3px solid #2BB0D7; }
    </style>

<span class="tooltip">Thing which can be hovered on</a>
<span class="custom info">
Text in tooltip goes here...
</span></span>

Which works all fine for Firefox and Chrome, obviously, but when I try it with Internet Explorer, the tooltip just doesn’t load/work…

HOWEVER, when I put a doctype at the top e.g:

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

It works fine in Internet Explorer, but all my other layout’s seem to break, i’ve never used a doctype, for the reasons of never needing one. Layouts been fine in all three browsers until this.

Is there something in the CSS which can be changed so the tooltip will work in Internet Explorer (without a doctype) or a similar tooltip CSS method? -Pref not javascript.

Hope i’ve explained my problem sufficiently, thanks.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T10:43:20+00:00Added an answer on June 15, 2026 at 10:43 am

    Well, you’re going to need to use a doctype in your new layouts moving forward. It’s nearing the end of 2012; having a doctype is pretty much required these days. For one, it ensures consistency between browsers: as you may have seen, the quirks modes of other browsers is similar to their standards modes… and vastly different from IE’s own quirks mode.

    That said, you can use an <a href> in place of a <span> if you must adhere to quirks mode for whatever reason, and :hover will work in IE just fine:

    <a href="#" class="tooltip">Thing which can be hovered on</a>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have HTML + CSS text. I need some lib with simple function like
I have some very simple HTML: <div id=advisor> <div id=print_this_container> <form> <input type=button value=
I have a very simple CSS opacity animation that animates some text in a
CSS I have some simple CSS to apply a negative text-indent value on the
I have an anchor tag with some simple CSS: div { background-color: gray; /*
I'm making some frontend experiments and I'd like to have a very basic webserver
I have some very simple code below that I can't get to validate on
I am a systems programmer, so i just know some basic css/html. I like
I am a beginner in web programming and have some very simple questions. I'm
I have a very simple HTML page, viewable on gh-pages with the following code:

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.