Note that there are some explanatory texts on larger screens.

plurals
  1. POJquery, Qtip2 - trying to get only a specific div from url
    primarykey
    data
    text
    <p>When user hovers over a link a tooltip appears. that tooltip needs to be a specific div from that links url. Everything works good so far, except i cant figure out how to fetch only that specific div (#tooltip)</p> <p>there will be many links on 1 page but as an example links look like this</p> <blockquote> <pre><code> &lt;a class="ttip" href="?category=weapons&amp;category_subclass=katana&amp;item=1"&gt;link 1&lt;/a&gt; &lt;a class="ttip" href="?category=weapons&amp;category_subclass=katana&amp;item=9"&gt;link 2&lt;/a&gt; </code></pre> </blockquote> <p>and script is</p> <blockquote> <pre><code> $(document).ready(function(){ $('.ttip').each(function(){ var link = 'index.php' + $(this).attr('href'); $(this).qtip({ content:{ ajax: { url: link } } }); }); }); </code></pre> </blockquote> <p>EDIT: i tried couple of things, including as it says on <a href="http://qtip2.com/plugins" rel="nofollow">http://qtip2.com/plugins</a></p> <blockquote> <p>Just like the jQuery.load method you can specify a custom selector after the URL, delimited by a space, in order to only return a particular sub-set of elements from the page!. For example:</p> <p>HTML url: 'myCustomPage2.html #table5' // Return the element with an ID of 'table5'</p> </blockquote> <p>so if i try...</p> <blockquote> <p>url: 'index.php?category=weapons&amp;category_subclass=katana&amp;item=1 #tooltip'</p> </blockquote> <p>...nothing happens. it just shows whole page. basically, this url im trying to fetch does some queries from database and echoes them in div #tooltip.</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

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