javascript - Tooltip box with arrow after hovering a profile picture -


i making tooltip box involve personal introduction text,my target tooltip box arrow displayed if using mouse hover profile picture......... have tried methods online not workable ...... can me?

here css code tooltip box

.tooltip {   display:none;   position:absolute;   border:1px solid #333;   background-color:#161616;   border-radius:5px;   padding:10px;   color:#fff;   font-size:12px arial; } 

here html code example

<table style="width:100%"> <tr> <td><img src="http://2017.igem.org/wiki/images/2/26/andrew.png" width="200" height="200" class="mastertooltip" title="name: ching yuet to;    hobby: hiking, watching movie;  believe fun can carry out research study  independently. think meaningful participate , promote synthetic  biology research.  can learn lot , make many international friends in boston! "></td> 

use ::before selector make arrow example

.tooltip-element {    display:none;    position:absolute;    border:1px solid #333;    background-color:#161616;    border-radius:5px;    padding:10px;    color:#fff;    font-size:12px arial;    bottom:100%;    left:0;  }  .tooltip-element::after{    content:'';    position:absolute;    width: 0;    height: 0;    border-style: solid;    border-width: 7px 5px 0 5px;    border-color: #161616 transparent transparent transparent;    bottom:-8px;    left:5px;  }  .tooltip{    position:relative;  }  .tooltip:hover .tooltip-element{    display:block;  }
<br><br><br><br><br><br><br>  <span class="tooltip">  <span class="tooltip-element">contnet tooltip</span>  test</span>


Comments

Popular posts from this blog

Is there a better way to structure post methods in Class Based Views -

performance - Why is XCHG reg, reg a 3 micro-op instruction on modern Intel architectures? -

jquery - Responsive Navbar with Sub Navbar -