Re: [jQuery] Serialization of form fields
This is what the form plugin is for. http://jquery.com/dev/svn/plugins/form/ On 9/18/06, Rey Bango [EMAIL PROTECTED] wrote: If I have 4 form fields like below and I wanted to serialize them in one big swoop instead of 1 by 1, how might I go about doing it? I know I can do this for the text fields; $([EMAIL PROTECTED]).serialize(); but I'm not sure if I can combine the selects into that call and minimize the code. Help? Rey... div class=tableBorder style=margin-bottom: 5px; table border=0 width=99% tr td bgcolor=##428E46 align=center colspan=2span class=headerProduct Search/span/td /tr tr tdSKU:/td tdinput type=text name=skusearch id=skusearch/td /tr tr tdTitle:/td tdinput type=text name=titleearch id=titlesearch/td /tr tr tdSite:/td tdselect name=sitesearch id=sitesearch optionTropical Traditions/option optionHealthyBuyersClub/option /select /td /tr tr tdType:/td tdselect name=typesearch id=typesearch optionRetail/option optionWholesale/option optionAll/option /select /td /tr tr td colspan=2 align=centerinput type=button name=searchBtn id=searchBtn value=Search /td /tr /table /div ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/ ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
Re: [jQuery] Serialization of form fields
Thanks Mike. I'll check that out. Rey... Mike Alsup wrote: This is what the form plugin is for. http://jquery.com/dev/svn/plugins/form/ On 9/18/06, Rey Bango [EMAIL PROTECTED] wrote: If I have 4 form fields like below and I wanted to serialize them in one big swoop instead of 1 by 1, how might I go about doing it? I know I can do this for the text fields; $([EMAIL PROTECTED]).serialize(); but I'm not sure if I can combine the selects into that call and minimize the code. Help? Rey... div class=tableBorder style=margin-bottom: 5px; table border=0 width=99% tr td bgcolor=##428E46 align=center colspan=2span class=headerProduct Search/span/td /tr tr tdSKU:/td tdinput type=text name=skusearch id=skusearch/td /tr tr tdTitle:/td tdinput type=text name=titleearch id=titlesearch/td /tr tr tdSite:/td tdselect name=sitesearch id=sitesearch optionTropical Traditions/option optionHealthyBuyersClub/option /select /td /tr tr tdType:/td tdselect name=typesearch id=typesearch optionRetail/option optionWholesale/option optionAll/option /select /td /tr tr td colspan=2 align=centerinput type=button name=searchBtn id=searchBtn value=Search /td /tr /table /div ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/ ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/ ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/
Re: [jQuery] Serialization of form fields
Great solution Francisco. Worked like a charm. Rey... Francisco Brito wrote: I just do [EMAIL PROTECTED] Serialize will ignore anything that's not an input anyway. -Brito On 9/18/06, *Rey Bango* [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] wrote: If I have 4 form fields like below and I wanted to serialize them in one big swoop instead of 1 by 1, how might I go about doing it? I know I can do this for the text fields; $([EMAIL PROTECTED]).serialize(); but I'm not sure if I can combine the selects into that call and minimize the code. Help? Rey... div class=tableBorder style=margin-bottom: 5px; table border=0 width=99% tr td bgcolor=##428E46 align=center colspan=2span class=headerProduct Search/span/td /tr tr tdSKU:/td tdinput type=text name=skusearch id=skusearch/td /tr tr tdTitle:/td tdinput type=text name=titleearch id=titlesearch/td /tr tr tdSite:/td tdselect name=sitesearch id=sitesearch optionTropical Traditions/option optionHealthyBuyersClub/option /select /td /tr tr tdType:/td tdselect name=typesearch id=typesearch optionRetail/option optionWholesale/option optionAll/option /select /td /tr tr td colspan=2 align=centerinput type=button name=searchBtn id=searchBtn value=Search /td /tr /table /div ___ jQuery mailing list discuss@jquery.com mailto:discuss@jquery.com http://jquery.com/discuss/ ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/ ___ jQuery mailing list discuss@jquery.com http://jquery.com/discuss/