Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Dynamically Loading Specifc Content from Page
9th November, 20:28
Post: #1
Dynamically Loading Specifc Content from Page
I'm attempting to convert from your earlier simpleTip solution to qTip.
With simpleTip I could use:

JS Code
onBeforeShow: function(){
   this.load(<a href="http://www.someURL.com/somePage.html+" target="_blank">http://www.someURL.com/somePage.html+</a>" [id='verSpecificField']:eq(1)");
}


to pull only the info from a very specific field on the incoming page. How do I achieve the same thing using qTip? Here's the code I'm trying to work out:

JS Code
// Create the tooltips only when document ready
$(document).ready(function(){
   // Use the each() method to gain access to each elements attributes
   $('area.fiveWs').each(function(){
      $(this).click(function() { return false;});
      $(this).qtip({
         content: {
               // Set the text to an image HTML string with the correct src URL to the loading image you want to use
               text: '<img src="/_layouts/images/CRPERSPC.GIF" alt="Loading..." style="border-style:none;vertical-align:middle;" HSPACE=71 VSPACE=12 />',
            prerender: true,
            once: false,
            url: $(this).attr('href'),      
               method: 'get',
               title: {
               text: 'FDG:  ' + $(this).text(), // Give the tooltip a title using each elements text
               button: 'Close' // Show a close link in the title
            }
         }
      });
   });
});


I'm sure the answer is in the API callbacks, but I've tried setting up beforeShow and beforeContentLoad to no avail. Am I missing something?
Find all posts by this user
Quote this message in a reply
23rd November, 00:13
Post: #2
Dynamically Loading Specifc Content from Page
ChuckLew, sorry for the late reply first off. Did you get this working as needed? If so could you reply with the details of how you solved it? Thanks!

Craig Thompson
Web Developer / Designer
Craigsworks
http://www.craigsworks.com
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Dynamic content from page variables kenswdev 0 400 9th February 18:06
Last Post: kenswdev
  Dynamic Content on first show, not page load TheOverbob 6 6,925 2nd August 13:01
Last Post: Craig
  [Solved] Change the content url dynamically depending on what link is moused over Arcadian 2 1,303 1st August 18:04
Last Post: actipsedreree
  [Solved] Displaying tooltip on page load/mouseover otherwise burghars 1 1,334 18th July 11:55
Last Post: Craig
  [Solved] modal with URL from another page? dod 2 1,492 2nd May 19:07
Last Post: Craig
  Load an HTML Page Within qTip Tooltip BruceBruce 3 3,303 19th January 12:17
Last Post: Craig
  Loading images: how to set the 'src'? Gustavo 2 1,451 26th October 23:15
Last Post: thomaspiter
  Google map not displaying dynamically ? ace310 0 919 15th September 23:52
Last Post: ace310
  [Solved] qTp modal dialog , on page load c0mrade 5 3,962 13th August 16:13
Last Post: mattsyk
  Callbacks fire on page load when they shouldn't anomalous 1 1,267 4th February 22:12
Last Post: anomalous



User(s) browsing this thread: 1 Guest(s)