Gabejazz, >From what I understand, it looks like you have a form that looks like:
<form> <input type="submit" name="action" value="doSomething" /> </form> If not, then I think this might be a problem with the code provided. Please try what Rick Waldron suggested, as it may give you a better perspective into the problem. Beware though, you will need Firefox and Firebug with the console enabled for this to work properly. I'd hate to be a stickler as this seems like an honest problem, however there are things I think we can all benefit from here: 1. Please provide a minimized example (read: paste minimal html+js replicating the problem to http://pastie.org or similar) 2. Send mails like this to the regular JQuery mailing list ( http://groups.google.com/group/jquery-en). If your example from step #1 proves to be un-answerable on the general list, then we can probably help as many of the jquery-dev's watch the jquery general list as well. Unfortunately this list is for the core development of jQuery itself and not support questions Hope it helps, -- Elijah On Tue, Aug 25, 2009 at 10:02 PM, Rick Waldron <waldron.r...@gmail.com>wrote: > Have you tried something simple like giving the <form> an id/name and > observing that? > > $('#form-id').submit(function () { > > console.log(this); > > return false; > }); > > ? > > > Rick > > > > On Tue, Aug 25, 2009 at 5:16 PM, Gabejazz <vijaz...@gmail.com> wrote: > >> >> When I execute this: >> >> 1. var myForm = $("form"); >> 2. myForm.submit(function() { >> 3. var self = $(this); >> 4. self.children("[name='action']").val("doSomething"); >> 5. >> 6. return true; >> 7. }); >> >> And then I debug it, doesn't pass beyond line 1. Recognize all kind of >> selectors except when I match a form. >> >> My environment is WAS 6.1, Struts 1.3.8. >> >> And my resources are: >> >> <script type="text/javascript" src="<html:rewrite page='/scripts/ >> jquery/js/jquery.js'/>"></script> >> <script type="text/javascript" src="<html:rewrite page='/scripts/ >> CommonScripts.js'/>"></script> >> <script type="text/javascript" src="<html:rewrite page='/scripts/ >> appScripts.js'/>"></script> >> >> The code is written in appScripts.js file. >> >> Can you help me please? I don't understand this situation. (-.-) >> >> PD: when I traverse a button searching for the form parent, it doesn't >> show the form node. >> >> >> > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "jQuery Development" group. To post to this group, send email to jquery-dev@googlegroups.com To unsubscribe from this group, send email to jquery-dev+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/jquery-dev?hl=en -~----------~----~----~----~------~----~------~--~---