[jQuery] Get success respose in ajaxSuccess?

2009-08-08 Thread cohq82
I am using $.ajax in jQuery and I have some thing running in $ ().ajaxSuccess(function(event, request, settings) {}); However I don't know how to get the html as in response of the success callback below: success: function(html) {}); How to pass html over to ajaxSuccess? I know I can insert a

[jQuery] Select tags within a string using jQuery

2009-08-02 Thread cohq82
Hi all, I have my website getting a value as a result of an ajax call. After that, I would like to insert that result (a string) into a tag. However, I would like to insert that result in a way that (1) it must have opacity = 0, then (2) it will slideDown() so the whole content list being pushed

[jQuery] Re: Select tags within a string using jQuery

2009-08-02 Thread cohq82
/javascriptexample.html maybe it helps ;) On 2 Aug., 21:13, cohq82 quang...@gmail.com wrote: Hi all, I have my website getting a value as a result of an ajax call. After that, I would like to insert that result (a string) into a tag. However, I would like to insert that result in a way that (1) it must

[jQuery] Re: Click event not fired when hide() called by blur()

2009-05-25 Thread cohq82
() {     if ( divclick ) return( divclick = false );     $('#bb').hide();   });  $('#bb')  .click(function() {     alert('test');     $('#aa').focus();   })   .mousedown(function(){      divclick = true;   }); }); On May 25, 2:01 am, cohq82 quang...@gmail.com wrote: Hi all, I am running

[jQuery] Click event not fired when hide() called by blur()

2009-05-24 Thread cohq82
Hi all, I am running into this specific use case and could not figure out how to do this. To simplify, I have a textarea and a DIV as code below. The way it supposes to work is when I focus on the textarea by clicking it, the DIV will show. Otherwise, it will be hidden. Then when I click the

[jQuery] Re: New inserted tag won't work with selector

2009-05-17 Thread cohq82
, 2009 at 2:14 AM, cohq82 quang...@gmail.com wrote: Is anyone aware of this problem? For example, the code below simply just inserts new P tag below the existing P's. When I move mouse over each of the P, I should see color change. Or when I click on new P, I should be able to trigger the P

[jQuery] New inserted tag won't work with selector

2009-05-14 Thread cohq82
Is anyone aware of this problem? For example, the code below simply just inserts new P tag below the existing P's. When I move mouse over each of the P, I should see color change. Or when I click on new P, I should be able to trigger the P click event. That did not happen. Anyone knows how to fix

[jQuery] Detect if drag outside of parent using jQuery UI Draggable

2009-04-27 Thread cohq82
Hi, I am making a inner DIV to be draggable using jQuery UI Draggable. The inner DIV can only move horizonally and fit within the outer DIV (parent). I want to have some detection mechanism so that if the inner DIV moved further left or right of the outer DIV, I will show something ( and arrow).

[jQuery] Re: Get element position relative to the body

2009-04-27 Thread cohq82
I found out this http://docs.jquery.com/CSS/position But it is not relative but rather absolute position. Any help on relative position? On Mar 26, 8:44 am, Shedokan shedo...@yahoo.com wrote: Is it possible to get the position of an object relative to the dcument if it's a floating object

[jQuery] Re: Custom error function in jQuery Validation plugin?

2009-04-13 Thread cohq82
Can someone help pls Thanks!! On Apr 12, 12:32 pm, cohq82 quang...@gmail.com wrote: I am new to jQuery validation plugin (http://docs.jquery.com/Plugins/ Validation). What I am trying to do is to have my own error message DIV with display:none initially. If there is error, I want to run

[jQuery] username validation using jQuery Validation plugin

2009-04-13 Thread cohq82
Hi all, Is there a way to validate username field (no space, only letters)? I don't want to modify the code. I know this can be done easily with if statement but I just want to see if the Validation plugin has this feature already:

[jQuery] Custom error function in jQuery Validation plugin?

2009-04-12 Thread cohq82
I am new to jQuery validation plugin (http://docs.jquery.com/Plugins/ Validation). What I am trying to do is to have my own error message DIV with display:none initially. If there is error, I want to run the fadein/fadeout to show that error. The structure of the input/error DIV like this: