My template/parent JSP has the following JQuery code in head secion

 <script language="javascript" type="text/javascript">
       var j = jQuery.noConflict();
       j(document).ready(function(){

           j('.queueForms').livequery(function(){

               var options = {
               url: '/Market/soDetailsQueueNote.action',
                   success: function() {
                       alert("success!");
                   }
               }
               j(this).ajaxForm(options);
               return false;
               });
           });
       </script>



My calling code is in another JSP which is included in the template
code above:

<form class="queueForms" id="htmlForm" action="/Market/
soDetailsQueueNote.action" method="post">
                                  Message: <input type="text"
name="message" value="Hello HTML" />

                                  <input type="submit" value="Echo as
HTML" />
  </form>


The only way to bind elements/forms that are loaded later on page,
seemed to be by using livequery.
The code does not work always. I mean it did work once in 30 attempts,
when i had alerts all over.

BUT if i copy this calling form in same
JSP template it starts working.

Do i need to do something special in order to make it work from the
included JSP???

Please help!!!

Reply via email to