Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>Here is a demo using qTip2 at <a href="http://qtip2.com/demos" rel="nofollow noreferrer">http://qtip2.com/demos</a>.</p> <p>HTML:</p> <pre><code>&lt;div id="demo-imagemap"&gt; &lt;h3&gt;ClICK TO TOGGLE X to see &lt;/h3&gt; &lt;img border="0" usemap="#myMap" alt="map" src="http://4.bp.blogspot.com/-Y6tP6TqJbfA/UX_vggdXEQI/AAAAAAAAAt4/ZfoonzP4Bxs/s1600/ih2LH.jpg"&gt; &lt;map id="myMap" name="myMap"&gt; &lt;area alt="place 1" shape="rect" coords="192,103,216,119" href="#"&gt; &lt;area alt="place 2" shape="rect" coords="128,269,156,293" href="#"&gt; &lt;area alt="place 3" shape="rect" coords="162,311,186,327" href="#"&gt; &lt;area alt="place 4" shape="rect" coords="172,207,200,235" href="#"&gt; &lt;area alt="place 5" shape="rect" coords="270,225,312,259" href="#"&gt; &lt;/map&gt; </code></pre> <p></p> <p>CSS:</p> <pre><code> /* Add some nice box-shadow-ness to the modal tooltip */ #ui-tooltip-modal { max-width: 420px; -moz-box-shadow: 0 0 10px 1px rgba(0, 0, 0, .5); -webkit-box-shadow: 0 0 10px 1px rgba(0, 0, 0, .5); box-shadow: 0 0 10px 1px rgba(0, 0, 0, .5); } #ui-tooltip-modal .ui-tooltip-content { padding: 10px; } </code></pre> <p>jQuery:</p> <pre><code> // Create the tooltips only when document ready $(document).ready(function () { // We'll target all AREA elements with alt tags (Don't target the map element!!!) $('area[alt]').qtip({ content: { attr: 'alt' // Use the ALT attribute of the area map for the content }, show: 'click', hide: 'click', style: { classes: 'ui-tooltip-tipsy ui-tooltip-shadow' } }); }); </code></pre> <p>Demo using your map, try centre located X, and a few on the left side:- <a href="http://jsfiddle.net/x5baU/11/" rel="nofollow noreferrer">http://jsfiddle.net/x5baU/11/</a></p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload