Subversion Repositories My Stuff

Rev

Rev 15 | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 15 Rev 27
Line 10... Line 10...
10
#######################################################################*/
10
#######################################################################*/
11
$(document).ready(function(){
11
$(document).ready(function(){
12
        checkBoxChange();
12
        checkBoxChange();
13
        toggleLinkClick();
13
        toggleLinkClick();
14
        checkboxChacked();
14
        checkboxChacked();
15
               
-
 
-
 
15
        var $comment;  
16
        var $options = {
16
        var $options = {
17
                        success: function(data) {
17
                        success: function(data) {
18
                var response = $(data).find('#comments');
18
                var response = $(data).find('#comments');
19
                $('#comments').replaceWith(response);
19
                $('#comments').replaceWith(response);
20
                $('#comment_form').find('form:first').validator().ajaxForm($options);
20
                $('#comment_form').find('form:first').validator().ajaxForm($options);
21
                checkboxChacked();
21
                checkboxChacked();
22
                checkBoxChange();
22
                checkBoxChange();
23
                toggleLinkClickSlide();
23
                toggleLinkClickSlide();
-
 
24
                $('#comment_form').find('textarea').val($comment);
24
                $('#comment_form > #comments-indicator').hide();
25
                $('#comment_form > #comments-indicator').hide();
25
                $.scrollTo( '#comments', 800, {onAfter:function(){
26
                $.scrollTo( '#comments', 800, {onAfter:function(){
26
                        $('.error').effect('pulsate');
27
                        $('.error').effect('pulsate');
27
                        $('.pagemessage').effect('pulsate');
28
                        $('.pagemessage').effect('pulsate');
28
                }
29
                }
29
                });
30
                });
30
                        },
31
                        },
31
                        beforeSubmit: function() {
32
                        beforeSubmit: function() {
-
 
33
                                $comment = $('#comment_form').find('textarea').val();
32
                                $('#comment_form > #comments-indicator').show();
34
                                $('#comment_form > #comments-indicator').show();
33
                        }
35
                        }
34
                };
36
                };
35
            $('#comment_form').find('form:first').validator().ajaxForm($options);
37
            $('#comment_form').find('form:first').validator().ajaxForm($options);
36
});
38
});