Post Reply 
 
Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Close button instead of link?
24th March, 20:20
Post: #1
Close button instead of link?
Hi,

I want to present a close button instead of just a hyperlink.
Also, I would like to be able to put the close button at the bottom of the tip.

Anybody have an idea of how to do this elegantly?
Find all posts by this user
Quote this message in a reply
25th March, 10:18
Post: #2
Close button instead of link?
That's easy as pie:

Note: I use onclick="return false;" to make sure that you are not sent to the top of the page again if you press the button.
Note2: put the style border:0; into your css.
JS Code
$("#tooltip").qtip({
   content: {
   text: 'This is my tooltip with a closebutton',
   title: {
      text: 'Free cake!',
      button: '<img o<strong></strong>nclick="return false;" style="border:0;" src="close.png" alt="Close" />'
      }
   }, 
   hide: 'mousedown',    
   style: { 
      width: 200,
      name: 'light'
      },
 
});


It will look like this (depending on your image of course):
[Image: closetip.png]
Find all posts by this user
Quote this message in a reply
25th March, 23:05
Post: #3
Close button instead of link?
Thanks, xpand2.
This works great!
Find all posts by this user
Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  Delete button not showing in I.E. 7 Derek 8 3,850 5th August 14:32
Last Post: jamesj
  [Solved] Change the content url dynamically depending on what link is moused over Arcadian 2 1,064 1st August 18:04
Last Post: actipsedreree
  Submit Button with Tooltip djinnov8 1 996 11th September 08:17
Last Post: Craig
  close modal dialog from inside the content siriusblack 3 2,301 21st April 17:57
Last Post: Craig
  Open a new tip on a tip close hari41980 3 1,653 31st August 11:49
Last Post: Craig
  Forcing Tips to Close Before Next Opens... PrimaryNumbers 10 2,403 17th August 16:07
Last Post: Craig
  Close a qTip from inside the tip content? ChimneyMedia 3 4,101 6th August 12:36
Last Post: Craig



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