Post Reply 
 
Thread Rating:
  • 1 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[Solved] [Solved] How to set qtip2 to hide after ajax completes?
3rd October, 12:17
Post: #1
[Solved] [Solved] How to set qtip2 to hide after ajax completes?
[php]
$('#submit').qtip({
content:{
text:status_tip_html('loading',SYSMSG.M00002),
ajax:{
url:SYSMSG.G00001,
type:'post',
dataType:'json',
data:ajax_data,
success:function(data){
/* success */
if(data.status === 'success'){
jQuery(_this.commentlist_id+data.des.post_id).prepend(data.des.content);
/* I d want to set this qtip to hide in here, how to write the codes? */

}
}
}
}
});
[/php]
I am not so clear. could you tell me? thank you.

'qTip is a good javascript library!',my mum said that:)
Find all posts by this user
Quote this message in a reply
3rd October, 13:17
Post: #2
RE: How to set qtip2 to hide after ajax completes?
Within the ajax callbacks, "this" refers to the API instance, so...
JS Code
success:function(data){
                /* success */
                if(data.status === 'success'){
                    jQuery(_this.commentlist_id+data.des.post_id).prepend(data.des.content);
                    /* I d want to set this qtip to hide in here, how to write the codes? */
                    this.hide();
                }
            }

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
3rd October, 13:41
Post: #3
RE: How to set qtip2 to hide after ajax completes?
(3rd October 13:17)Craig Wrote:  Within the ajax callbacks, "this" refers to the API instance, so...
JS Code
success:function(data){
                /* success */
                if(data.status === 'success'){
                    jQuery(_this.commentlist_id+data.des.post_id).prepend(data.des.content);
                    /* I d want to set this qtip to hide in here, how to write the codes? */
                    this.hide();
                }
            }
thanks again man.
I can feel you have a great powerSmile

'qTip is a good javascript library!',my mum said that:)
Find all posts by this user
Quote this message in a reply
4th October, 13:27 (This post was last modified: 4th October 13:28 by kmvan.)
Post: #4
RE: [Solved] How to set qtip2 to hide after ajax completes?
excuse me. I d want to know, how to make the effect in qtip after ajax?
JS Code
success:function(data){
	if(data.status === 'success'){
		this.set('content.text',data.des.content);
 
		/* ↓↓↓↓↓ is it right? i d want to "reposition" the qtip, but it has not effect. ↓↓↓↓↓ */
		this.reposition({at:'top center',my:'bottom center'});
		/* ↑↑↑↑↑ end the codes ↑↑↑↑↑ */
 
	}else{
 
	}
}

thank you very much.

'qTip is a good javascript library!',my mum said that:)
Find all posts by this user
Quote this message in a reply
4th October, 17:13
Post: #5
RE: [Solved] How to set qtip2 to hide after ajax completes?
Use this.set, not this.reposition Smile

JS Code
this.set({ 'position.at': 'top center', 'position.my': 'bottom center'});

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
4th October, 23:51
Post: #6
RE: [Solved] How to set qtip2 to hide after ajax completes?
thank you very muchSmile
And i d want to know where to get your idea? The documentation does not describe, where i get it? Thank you CraigSmile

'qTip is a good javascript library!',my mum said that:)
Find all posts by this user
Quote this message in a reply
5th October, 00:26
Post: #7
RE: [Solved] How to set qtip2 to hide after ajax completes?
Here you go: http://craigsworks.com/projects/qtip2/docs/api/#set

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
5th October, 23:56
Post: #8
RE: [Solved] [Solved] How to set qtip2 to hide after ajax completes?
thank youSmile
I got it : http://craigsworks.com/projects/qtip2/docs/api/#options

'qTip is a good javascript library!',my mum said that:)
Find all posts by this user
Quote this message in a reply
Post Reply 


Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  qTip2 and Wordpress integration Tutorial newbie2012 0 184 17th April 03:35
Last Post: newbie2012
  [Solved] HTML for attaching qTip2 to <a> tag? paigepauli 2 280 26th March 22:12
Last Post: paigepauli
  Wordpress- qtip2-newbie proch 3 1,648 6th January 16:02
Last Post: jmillspaysbills
  Loading Multiple qTip2 Scripts on the Same Page jdiggs332 1 616 18th December 20:56
Last Post: Craig
  [Solved] How to set the "z-index" in qtip2? kmvan 5 1,135 21st October 19:11
Last Post: Craig
  [Solved] How to set qtip2 to center of screen? kmvan 4 1,101 12th October 03:18
Last Post: kmvan
  [Solved] How to set qtip2 to Full Screen? kmvan 3 874 28th September 00:57
Last Post: kmvan
  List of qTip2 Implementation Samples kiddailey 4 5,348 10th August 08:08
Last Post: ajkochanowicz
  How to hide qTip top border rakeshrawatg 1 2,760 5th June 00:06
Last Post: Craig



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