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 891055
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 15, 20262026-05-15T13:49:49+00:00 2026-05-15T13:49:49+00:00

i have a simple question. for a website, i want to create an info

  • 0

i have a simple question.
for a website, i want to create an “info note” that appears by hovering a link, as facebook does when hovering some thumbnails you know?

here is the thing i have for the moment, so you can see the bug i have :

alt text http://img641.imageshack.us/img641/1571/notes.gif
so the only problem is : the small “info note” stay on the left of my div. the goal is that this small note appears well-placed, over the right icon… :/

do javascript is required to do this ? or can we do it with css only (and in this case, what’s wrong with my code? :/)

for information, here is the html code for this :

<a href="#" onmouseover="infohover('show', 'aaa');" onmouseout="infohover('hide', 'aaa');">
    <span class="infohover" id="aaa"><span class="infohover_in">J'aime !</span></span>
    <img src="<?php echo $basedir; ?>images/temp/heart.png" alt="" />
</a>

and the css :

.infohover { display: none; position: relative; float: left; margin-top: -30px; margin-left: -4px; opacity: 0.9; background: url('<?php echo $basedir; ?>images/temp/infohover_arrow.gif') 8px 24px no-repeat; }
.infohover_in { display: block; padding: 6px; margin-bottom: 6px; background-color: #000000; color: #ffffff; border-radius: 3px; }

ps: don’t pay attention to the “not perfect written” code, i write it quickly for the test, to see if i can do it or no… will clean it later 🙂

thanks a lot for your help and ideas ! have a nice day !

  • 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-05-15T13:49:49+00:00Added an answer on May 15, 2026 at 1:49 pm

    No JavaScript is required here.

    HTML

    <a href="#" class="tooltip">Icon 1<span class="tooltip">Tooltip 1</span></a>
    <a href="#" class="tooltip">Icon 2<span class="tooltip">Tooltip 2</span></a>
    <a href="#" class="tooltip">Icon 3<span class="tooltip">Tooltip 3</span></a>
    

    CSS

    a.tooltip {
        text-decoration: none;
        position: relative;
    }
    a.tooltip .tooltip {
        position: absolute;
        top: -1.1em;
        left: 0;
        display: none;
        color: black;
        white-space: nowrap;
    }
    a.tooltip:hover .tooltip {
        display: block;
    }  
    

    The magic is in a.tooltip { position: relative; }. Whenever you have an element with position: relative, elements within that element that have position: absolute will position relatively to that parent element. This, plus a little :hover pseudo action makes your problem very easy to solve.

    Live demo.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I want to have a very simple editor for my website that i wrote
I'm new to postgreSQL and I have a simple question: I'm trying to create
I have a very simple question. I want to test whether a particular port
I am learning LINQ and have a very simple question that I think will
Simple question: do I have to delete or delete [] c ? Does the
help out a noob with a simple web development question?? I want to create
I want to use Qt to create a simple GUI application that can play
This is probably a simple question... I have a UIView with a button that
I just have one simple question about XSS attack. I know that you can
I have a simple question. Is there a way ( using reflections I suppose

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.