[jQuery] [jQuery Tabs] Select tab from link
Good day everyone. I'm using Jquery Tabs UI and loading content via Ajax. I'm now trying to select one of the tabs from a link on another page. I'm not having any luck with the example on the jquery docs page. When I assign the #standard as an ID on the A tag it does not load the content of that tab. Example: Users Does anyone have any suggestions? Thanks!! Stephen // Jquery Stuff $(document).ready(function(){ var $tabs = $("#tabs-container").tabs(); $('#standard').click(function() { // bind click event to link $tabs.tabs('select', 2); // switch to third tab return false; }); }); // HTML Stuff Administrators Users Process Users User Activity Database Backup // Jquery Documentation http://docs.jquery.com/UI/Tabs#...select_a_tab_from_a_text_link_instead_of_clicking_a_tab_itself
[jQuery] Re: google map with jquery and php(please help me)
That is a very nice tutorial. It's too bad that the creator stylized it that way... makes me head hurt just looking at it. On Dec 7, 6:57 pm, Charlie wrote: > This set of many tutorials is one of the best Google map resources you can > find:http://econym.org.uk/gmap/ > StephenJacob wrote:I'd suggest checking out the Google API documentation for > examples. You can also look into some jquery google map examples at > ajaxrain.com ... but i think you'll find more things useful at the google api > site.http://code.google.com/apis/maps/documentation/index.htmlhttp://www.ajaxrain.com/searchOn > Dec 7, 1:30 pm, hamed7<63hosse...@gmail.com>wrote:hi i need some code like > google map with jquery and php i dont want use api,i want create some page > with some map for user can click on map and save some information on map and > show like google map.
[jQuery] Re: google map with jquery and php(please help me)
I'd suggest checking out the Google API documentation for examples. You can also look into some jquery google map examples at ajaxrain.com ... but i think you'll find more things useful at the google api site. http://code.google.com/apis/maps/documentation/index.html http://www.ajaxrain.com/search On Dec 7, 1:30 pm, hamed7 <63hosse...@gmail.com> wrote: > hi > > i need some code like google map with jquery and php > > i dont want use api,i want create some page with some map for user can > click on map > and save some information on map and show like google map.
[jQuery] Re: Load image when they are visible
Not a problem man! I've realized that half the problem finding answers is wording the question properly. Good luck with your project! On Nov 19, 4:40 pm, CrustyDOD wrote: > Yes, that's it.. > > Was so looking for the wrong thing.. > > Thanks man. > > On Nov 19, 9:08 pm,StephenJacob wrote: > > > I think this is what you're looking for. Haven't tested it myself, but > > this is what i found with a quick search in google for "jquery load > > images on scroll" > > >http://www.appelsiini.net/2007/9/lazy-load-images-jquery-plugin > > > On Nov 19, 2:37 pm, CrustyDOD wrote: > > > > Hey guys, > > > > I've been searching all over if its possible to make the same effect > > > that YouTube has. > > > Loading images when they are visible. > > > > If you have no idea what i'm talking about, go to YouTube, do a search > > > for some video and > > > when you scroll down the list of all found videos, thumbnails of each > > > video will be loaded once > > > they are visible (in the visible area of the browser). > > > > Any ideas how to do this effect? Load images only when they are inside > > > the viewable > > > area of a browser..
[jQuery] Re: Load image when they are visible
I think this is what you're looking for. Haven't tested it myself, but this is what i found with a quick search in google for "jquery load images on scroll" http://www.appelsiini.net/2007/9/lazy-load-images-jquery-plugin On Nov 19, 2:37 pm, CrustyDOD wrote: > Hey guys, > > I've been searching all over if its possible to make the same effect > that YouTube has. > Loading images when they are visible. > > If you have no idea what i'm talking about, go to YouTube, do a search > for some video and > when you scroll down the list of all found videos, thumbnails of each > video will be loaded once > they are visible (in the visible area of the browser). > > Any ideas how to do this effect? Load images only when they are inside > the viewable > area of a browser..
[jQuery] Re: validation: how do I call a function to perform after a validation is done?
Hmm, i'm not really sure how to pull that off. I would look into the showErrors option or possibly the Valid function. http://docs.jquery.com/Plugins/Validation/validate http://docs.jquery.com/Plugins/Validation/valid Good luck and let us know how things turn out for ya! On Nov 18, 3:47 pm, "Atkinson, Sarah" wrote: > I want the function to trigger when there are errors it's to alter the > position of both the errors and other elements on the page. > > So I got the function to fire but I can't seem to changes the css on the > error boxes. > $('label .error').css({'left' : basePossitionOffset.left}); > Does not work. > > I should be able to alter the error messages just like anyother element in > the DOM right? > > On 11/18/09 3:34 PM, "StephenJacob" wrote: > > It depends on your method of validation. Here is the form/validation > system I use for my contact form. Hope this helps! > > > > > > > $(document).ready(function() { > > $("#contactForm").validate({ > rules: { > fullname: { > required: true, > minlength: 2 > }, > email: { > required: true, > email: true > }, > company: { > required: true, > minlength: 2 > }, > phone: { > required: true, > minlength: 2 > }, > }, > messages: { > fullname: '<span class="error">Please enter your > <b>full name</b>.</ > span>', > email: '<span class="error">Please enter a valid > <b>email address</ > b>.</span>', > company: '<span class="error">Please enter your > <b>company</b>.</ > span>', > phone: '<span class="error">Please enter your > <b>phone number</b>.</ > span>' > }, > submitHandler: function(form) { > > $('#contactForm').ajaxSubmit({ > resetForm: true, > target: '#success', > success: function() { > > $("#success").fadeIn('slow').fadeTo(5000, 1).fadeOut('slow'); > } > }); > } > }); > > }); > > > > > > //FORM GOES HERE > > > > On Nov 18, 3:08 pm, "Atkinson, Sarah" > wrote: > > > Do I have to create a custom method and stick a function in there?
[jQuery] Re: validation: how do I call a function to perform after a validation is done?
It depends on your method of validation. Here is the form/validation
system I use for my contact form. Hope this helps!
$(document).ready(function() {
$("#contactForm").validate({
rules: {
fullname: {
required: true,
minlength: 2
},
email: {
required: true,
email: true
},
company: {
required: true,
minlength: 2
},
phone: {
required: true,
minlength: 2
},
},
messages: {
fullname: 'Please enter your
full name.
span>',
email: 'Please enter a valid
email address
b>.',
company: 'Please enter your
company.
span>',
phone: 'Please enter your phone
number.
span>'
},
submitHandler: function(form) {
$('#contactForm').ajaxSubmit({
resetForm: true,
target: '#success',
success: function() {
$("#success").fadeIn('slow').fadeTo(5000, 1).fadeOut('slow');
}
});
}
});
});
//FORM GOES HERE
On Nov 18, 3:08 pm, "Atkinson, Sarah"
wrote:
> Do I have to create a custom method and stick a function in there?
[jQuery] Re: Removed iframe still loads
No, thank you for posting the solution! Good job and good luck. On Nov 18, 10:14 am, Subtle wrote: > Hi, actually I currently don't. Basically I have an iframe on a page > that loads a very large file. On the page there is a button that when > clicked, will remove the iframe's container (the div): $ > ('#iframeContainer').remove(); > > What I expected to happen was that after the iframeContainer was > removed, the browser would stop trying to finish the request made by > the iframe. Instead, even though the iframe was removed, the browser > was still trying to load the big file. > > I think I figured it out though. If I set the src on the iframe to > something like src="#" and then remove it, then it appears to work and > the iframe stops loading. > > Thanks > > On Nov 18, 8:08 am, StephenJacob wrote: > > > Hi Subtle, I'm a little confused to exactly what's going on. Do you > > have a link/example I can check out? > > > On Nov 18, 10:01 am, Subtle wrote: > > > > Actually that still didn't work... > > > > On Nov 18, 7:54 am, Subtle wrote: > > > > > Figured it out. I was removing the iframes container (div), and not > > > > the iframe specifically. To fix the problem I had to target the > > > > iframe specifically and remove it, and then it's container. > > > > > On Nov 18, 7:45 am, Subtle wrote: > > > > > > Anyone? > > > > > > On Nov 4, 4:52 pm, Subtle wrote: > > > > > > > When trying to remove aniframefrom the dom (i.e. $('iframe').remove > > > > > > ()) while theiframeis still loading, theiframeisremoved, however > > > > > > the main browsers progress bar indicates that theiframeis still > > > > > > loading. Is there a way to stop it from loading and remove it? > > > > > > > Thanks.
[jQuery] Re: Removed iframe still loads
Hi Subtle, I'm a little confused to exactly what's going on. Do you have a link/example I can check out? On Nov 18, 10:01 am, Subtle wrote: > Actually that still didn't work... > > On Nov 18, 7:54 am, Subtle wrote: > > > Figured it out. I was removing the iframes container (div), and not > > the iframe specifically. To fix the problem I had to target the > > iframe specifically and remove it, and then it's container. > > > On Nov 18, 7:45 am, Subtle wrote: > > > > Anyone? > > > > On Nov 4, 4:52 pm, Subtle wrote: > > > > > When trying to remove aniframefrom the dom (i.e. $('iframe').remove > > > > ()) while theiframeis still loading, theiframeisremoved, however > > > > the main browsers progress bar indicates that theiframeis still > > > > loading. Is there a way to stop it from loading and remove it? > > > > > Thanks.
[jQuery] Re: Jquery Tabs FOUC (Hide inactive tab panel)
Here is the example page: http://www.turnstylecreative.com/new/work.php I've also tried the follow tutorial with no luck. http://www.learningjquery.com/2008/10/1-way-to-avoid-the-flash-of-unstyled-content On Nov 16, 10:56 am, StephenJacob wrote: > Does anyone have any experience with the Jquery tab system? Below is > the instructions they've suggested to help prevent FOUC. Obviously, by > adding this CSS code all it does is hide the div's completely. > > I'm trying to find out how to hide the inactive Tabs upon page load > and then remove/activate them when a user clicks the tab. > > http://docs.jquery.com/UI/Tabs#options > > ...prevent a FOUC (Flash of Unstyled Content) before tabs are > initialized > > Add the necessary classes to hide an inactive tab panel to the HTML > right away - note that this will not degrade gracefully with > JavaScript being disabled: > > ... > > ... > > > Required CSS: > > .ui-tabs .ui-tabs-hide { > display: none; > > }
[jQuery] Jquery Tabs FOUC (Hide inactive tab panel)
Does anyone have any experience with the Jquery tab system? Below is the instructions they've suggested to help prevent FOUC. Obviously, by adding this CSS code all it does is hide the div's completely. I'm trying to find out how to hide the inactive Tabs upon page load and then remove/activate them when a user clicks the tab. http://docs.jquery.com/UI/Tabs#options ...prevent a FOUC (Flash of Unstyled Content) before tabs are initialized Add the necessary classes to hide an inactive tab panel to the HTML right away - note that this will not degrade gracefully with JavaScript being disabled: ... ... Required CSS: .ui-tabs .ui-tabs-hide { display: none; }
[jQuery] Re: Jquery Tabs
After further research it appears they are both doing the same thing when loading content. Does anyone have any suggestions or experience working with things like this? I understand that Jquery can not "tabify" the content until the page is loaded.. there for, the HTML must load the page and then organize it into the tab system.. There has to be some kind of trick to hide the content until the page or tab system completely loads? Thanks! On Nov 12, 1:56 pm, StephenJacob wrote: > Issue Resolved. > > I stopped using the Jquery Tabs and started > usinghttp://flowplayer.org/tools/demos/tabs/index.html > > On Nov 12, 11:06 am, StephenJacob wrote: > > > I'm having an issue, which seems common, when loading tab content > > using the Jquery Tab plugin. It seems the content loads on the page > > prior to being "tabbed". This causes the page to jump around for a > > split second before the content loads completely. > > > Is there any way of fixing this issue? > > >http://docs.jquery.com/UI/Tabs > > > Thanks!
[jQuery] Re: Jquery Tabs
Issue Resolved. I stopped using the Jquery Tabs and started using http://flowplayer.org/tools/demos/tabs/index.html On Nov 12, 11:06 am, StephenJacob wrote: > I'm having an issue, which seems common, when loading tab content > using the Jquery Tab plugin. It seems the content loads on the page > prior to being "tabbed". This causes the page to jump around for a > split second before the content loads completely. > > Is there any way of fixing this issue? > > http://docs.jquery.com/UI/Tabs > > Thanks!
[jQuery] Jquery Tabs
I'm having an issue, which seems common, when loading tab content using the Jquery Tab plugin. It seems the content loads on the page prior to being "tabbed". This causes the page to jump around for a split second before the content loads completely. Is there any way of fixing this issue? http://docs.jquery.com/UI/Tabs Thanks!
[jQuery] Re: Submitting after Validation
I'm learning! I replaced: $("#success").fadeIn("slow"); var clearSuccess = function() { $('#success').fadeOut('slow', function () { $("#success").remove(); }); }; window.setTimeout(clearSuccess,3000); With: $("#success").fadeIn('slow').fadeTo(5000, 1).fadeOut('slow'); Viola! On Nov 5, 3:46 pm, StephenJacob wrote: > Thanks for the insight Jules! With that it pushed me in the direction > that I finally got working. > > 1 issue remaining that isn't that big of a deal but i would love to > resolve it. > > After submitting the form it opens a div #success and closes it after > 3 seconds. If i submit the form again, without refreshing the page, > it doesn't show this success message. Any idea why it's not triggering > the success message again? > > $(document).ready(function() { > > $("#contactForm").validate({ > rules: { > fullname: { > required: true, > minlength: 2 > }, > email: { > required: true, > email: true > }, > company: { > required: true, > minlength: 2 > }, > phone: { > required: true, > minlength: 2 > }, > }, > messages: { > fullname: 'Please enter > your full name b>.', > email: 'Please enter a > valid email address b>.', > company: 'Please enter > your company. span>', > phone: 'Please enter your > phone number b>.' > }, > submitHandler: function(form) { > > $('#contactForm').ajaxSubmit({ > resetForm: true, > target: '#success', > success: function() { > $("#success").fadeIn("slow"); > var clearSuccess = function() > { $('#success').fadeOut('slow', > function() { $("#success").remove(); }); }; > > window.setTimeout(clearSuccess,3000); > } > > }); > } > }); > > }); > > On Nov 4, 5:03 pm, Jules wrote: > > > Hi Stephen, > > > Try using input type="button" instead of "submit" as per my example > > below. Excuse the aspx :). > > > register.aspx code. > > > string usrName = Request["userName"]; > > Response.Clear(); > > Response.Write("Hello " + usrName); > > Response.End(); > > > -- client side code and html > > > > > $(document).ready(function() { > > $("form").validate(); > > $("#userName").rules("add", > > { > > required: true, > > messages: { required: "User Name is required." } > > }); > > > $("#submitForm").click(function() { > > > if ($("form").valid()) { > > $.post("register.aspx", $("form").serialize(), function > > (data, status) { $("#message").text(data) }, "text") > > } > > }); > > }); > > > > > > > > > > > > > > > > User Name: > > > > > > > > > value="Submit" /> > > > > > > > > > > > --- end of client side code and html > > > On Nov 5, 7:41 am, StephenJacob wrote: > > > > Just to clarify, the $.post function works perfectly and returns my > > > json results. Due to th
[jQuery] Re: Submitting after Validation
Thanks for the insight Jules! With that it pushed me in the direction that I finally got working. 1 issue remaining that isn't that big of a deal but i would love to resolve it. After submitting the form it opens a div #success and closes it after 3 seconds. If i submit the form again, without refreshing the page, it doesn't show this success message. Any idea why it's not triggering the success message again? $(document).ready(function() { $("#contactForm").validate({ rules: { fullname: { required: true, minlength: 2 }, email: { required: true, email: true }, company: { required: true, minlength: 2 }, phone: { required: true, minlength: 2 }, }, messages: { fullname: 'Please enter your full name.', email: 'Please enter a valid email address.', company: 'Please enter your company.', phone: 'Please enter your phone number.' }, submitHandler: function(form) { $('#contactForm').ajaxSubmit({ resetForm: true, target: '#success', success: function() { $("#success").fadeIn("slow"); var clearSuccess = function() { $('#success').fadeOut('slow', function() { $("#success").remove(); }); }; window.setTimeout(clearSuccess,3000); } }); } }); }); On Nov 4, 5:03 pm, Jules wrote: > Hi Stephen, > > Try using input type="button" instead of "submit" as per my example > below. Excuse the aspx :). > > register.aspx code. > > string usrName = Request["userName"]; > Response.Clear(); > Response.Write("Hello " + usrName); > Response.End(); > > -- client side code and html > > > $(document).ready(function() { > $("form").validate(); > $("#userName").rules("add", > { > required: true, > messages: { required: "User Name is required." } > }); > > $("#submitForm").click(function() { > > if ($("form").valid()) { > $.post("register.aspx", $("form").serialize(), function > (data, status) { $("#message").text(data) }, "text") > } > }); > }); > > > > > > > > > User Name: > > > > value="Submit" /> > > > > > > --- end of client side code and html > > On Nov 5, 7:41 am, StephenJacob wrote: > > > Just to clarify, the $.post function works perfectly and returns my > > json results. Due to the limitations of the validation system i was > > using (no remote options) i had to begin using the standard > > jquery .validate library. > > > Please help me understand how to implement the .Validate w/ my HTML > > form. > > > As you can see the $.post option has the process.php written in the > > Jquery and leaves the HTML form action blank. With the > > Jquery .Validate, I need to define the process.php as the Action > > correct? If so, why does the form continue to submit normally? > > > Thanks for all the help everyone! I think with a bit more guidance > > i'll have a really strong understanding of the validation system. > > > On Nov 4, 3:33 pm, StephenJacob wrote: > > > > @Leonard, unfortunately it's not due to the function argument. > > > > @Dylan, I've looked at this tutorial a few times. It's not usin
[jQuery] Re: Submitting after Validation
Just to clarify, the $.post function works perfectly and returns my json results. Due to the limitations of the validation system i was using (no remote options) i had to begin using the standard jquery .validate library. Please help me understand how to implement the .Validate w/ my HTML form. As you can see the $.post option has the process.php written in the Jquery and leaves the HTML form action blank. With the Jquery .Validate, I need to define the process.php as the Action correct? If so, why does the form continue to submit normally? Thanks for all the help everyone! I think with a bit more guidance i'll have a really strong understanding of the validation system. On Nov 4, 3:33 pm, StephenJacob wrote: > @Leonard, unfortunately it's not due to the function argument. > > @Dylan, I've looked at this tutorial a few times. It's not using the > official Jquery Validate system and hasn't been able to help me fill > in any gaps in my learning curve... It seems that every tutorial has > their own convoluted system to doing validation.. And the ones that do > use the standard validation system none of them thoroughly explain the > form submission part. > > This is my current working Validation code + Submit function that does > not work properly. It post the page normally, like any HTML form > would. > > $(document).ready(function(){ > > $("#contactForm").validate({ > > rules: { > fullname: { > required: true, > minlength: 2 > }, > email: { > required: true, > email: true > }, > company: { > required: true, > minlength: 2 > }, > phone: { > required: true, > minlength: 2 > }, > > }, > messages: { > fullname: 'Please enter your > full name. span>', > email: 'Please enter a valid > email address b>.', > company: 'Please enter your > company. span>', > phone: 'Please enter your > phone number. span>' > }, > submitHandler: function() { > form.submit(); > } > }); > > }); > > // HTML FORM > > > //Stuff goes here > > > // WORKING VALIDATION USING LIMITED VALIDATION SYSTEM > > $(document).ready(function(){ > > $("#signupForm #submit").click(function(){ > > $(".error").hide(); > var hasError = false; > var emailReg = /^([\w-\.]+@([\w-]+\.)+[\w-]{2,4})?$/; > > var regarding_Val = $("#regarding").val(); > var message_Val = $("#message").val(); > var subcontact = $("#subcontact").val(); > > var fullname_Val = $("#fullname").val(); > if(fullname_Val == '') { > $("#fullname").after('Please > enter your full > name.'); > hasError = true; > } > > var company_Val = $("#company").val(); > if(company_Val == '') { > $("#company").after('Please enter > your > company.'); > hasError = true; > } > > var phone_Val = $("#phone").val(); > if(phone_Val == '') { > $("#phone").after('Please enter a > phone > number.'); > hasError = true; > } > > var email_Val = $("#email").val(); > if(email_Val == '') { > $("#email").after('Please enter > an email > address.'); > hasError = true; > } else if(!emailReg.test(email_Val)) { > $("#email").after('Please enter a > valid email > address.'); > hasError = true; > } > > if(hasError == false) { &
[jQuery] Re: Submitting after Validation
@Leonard, unfortunately it's not due to the function argument. @Dylan, I've looked at this tutorial a few times. It's not using the official Jquery Validate system and hasn't been able to help me fill in any gaps in my learning curve... It seems that every tutorial has their own convoluted system to doing validation.. And the ones that do use the standard validation system none of them thoroughly explain the form submission part. This is my current working Validation code + Submit function that does not work properly. It post the page normally, like any HTML form would. $(document).ready(function(){ $("#contactForm").validate({ rules: { fullname: { required: true, minlength: 2 }, email: { required: true, email: true }, company: { required: true, minlength: 2 }, phone: { required: true, minlength: 2 }, }, messages: { fullname: 'Please enter your full name.', email: 'Please enter a valid email address.', company: 'Please enter your company.', phone: 'Please enter your phone number.' }, submitHandler: function() { form.submit(); } }); }); // HTML FORM //Stuff goes here // WORKING VALIDATION USING LIMITED VALIDATION SYSTEM $(document).ready(function(){ $("#signupForm #submit").click(function(){ $(".error").hide(); var hasError = false; var emailReg = /^([\w-\.]+@([\w-]+\.)+[\w-]{2,4})?$/; var regarding_Val = $("#regarding").val(); var message_Val = $("#message").val(); var subcontact = $("#subcontact").val(); var fullname_Val = $("#fullname").val(); if(fullname_Val == '') { $("#fullname").after('Please enter your full name.'); hasError = true; } var company_Val = $("#company").val(); if(company_Val == '') { $("#company").after('Please enter your company.'); hasError = true; } var phone_Val = $("#phone").val(); if(phone_Val == '') { $("#phone").after('Please enter a phone number.'); hasError = true; } var email_Val = $("#email").val(); if(email_Val == '') { $("#email").after('Please enter an email address.'); hasError = true; } else if(!emailReg.test(email_Val)) { $("#email").after('Please enter a valid email address.'); hasError = true; } if(hasError == false) { $.post("process.php", $("#signupForm").serialize(), function(data){ $('#signupForm').clearForm(); if (data.success) { $("#success").html(data.message); } }, "json" ); } return false; }); }); On Oct 29, 6:22 am, Dylan wrote: > Have a look at some of the ideas from this > ...http://tutorialzine.com/2009/09/fancy-contact-form/ > > On Oct 27, 8:16 pm,StephenJacob wrote: > > > Leonardo, I've been looking into the submitHandler option but i'm > > having problems getting it to work correctly. Here is a sample of the > > code i'm testing. > > > $("#signupForm").validate({ > > > rules: { > > fullname: "required", > > company: "required&qu
[jQuery] Re: Submitting after Validation
Thanks Leonardo, I've tried to implement AjaxSubmit and the Jquery.Post but have had no luck. The form keeps submitting the normal way no matter what I do. On Oct 28, 7:48 am, Leonardo K wrote: > form.submit() just submit in the normal way. > > To submit via ajax you could use this > plugin:http://www.malsup.com/jquery/form/#apithen use: > > $(form).ajaxSubmit(); > > or you can do by yourself withouth any plugin via jQuery > Post:http://docs.jquery.com/Ajax/jQuery.post > > On Tue, Oct 27, 2009 at 18:16, StephenJacob > wrote: > > > > > Leonardo, I've been looking into the submitHandler option but i'm > > having problems getting it to work correctly. Here is a sample of the > > code i'm testing. > > > $("#signupForm").validate({ > > > rules: { > > fullname: "required", > > company: "required", > > phone: "required", > > email: { > > required: true, > > email: true > > } > > }, > > messages: { > > fullname: "Please enter your fullname", > > company: "Please enter a company name", > > phone: "Please enter a phone number", > > email: "Please enter a valid email address" > > }, > > submitHandler: function() { > > form.submit(); > > } > > > }); > > > > action="process.php"> > > > > * Name: > > > class="textbox" /> > > > > > > * Company: > > > class="textbox" /> > > > > > > * Email: > > > > > > > > * Phone: > > > > > > > > Message: > > > textarea> > > > > > > > > > > > > > > > > > On Oct 27, 1:42 pm, Leonardo K wrote: > > > Look the submitHandler option: > > > >http://docs.jquery.com/Plugins/Validation/validate#toptions > > > > On Tue, Oct 27, 2009 at 15:02, StephenJacob > >wrote: > > > > > I'm trying to create a contact form using Jquery Validation and Ajax > > > > Submit. I'm having a problem figuring out the best way to submit the > > > > results to a php file. Below is a break down of my validation code. > > > > > $().ready(function(){ > > > > > $("#signupForm").validate({ > > > > > rules: { > > > > fullname: "required", > > > > company: "required", > > > > phone: "required", > > > > email: { > > > > required: true, > > > > email: true > > > > } > > > > }, > > > > messages: { > > > > fullname: "Please enter your fullname", > > > > company: "Please enter a company name", > > > > phone: "Please enter a phone number", > > > > email: "Please enter a valid email address" > > > > } > > > > > }); > > > > > });
[jQuery] Re: Submitting after Validation
Leonardo, I've been looking into the submitHandler option but i'm having problems getting it to work correctly. Here is a sample of the code i'm testing. $("#signupForm").validate({ rules: { fullname: "required", company: "required", phone: "required", email: { required: true, email: true } }, messages: { fullname: "Please enter your fullname", company: "Please enter a company name", phone: "Please enter a phone number", email: "Please enter a valid email address" }, submitHandler: function() { form.submit(); } }); * Name: * Company: * Email: * Phone: Message: On Oct 27, 1:42 pm, Leonardo K wrote: > Look the submitHandler option: > > http://docs.jquery.com/Plugins/Validation/validate#toptions > > On Tue, Oct 27, 2009 at 15:02, StephenJacob > wrote: > > > > > I'm trying to create a contact form using Jquery Validation and Ajax > > Submit. I'm having a problem figuring out the best way to submit the > > results to a php file. Below is a break down of my validation code. > > > $().ready(function(){ > > > $("#signupForm").validate({ > > > rules: { > > fullname: "required", > > company: "required", > > phone: "required", > > email: { > > required: true, > > email: true > > } > > }, > > messages: { > > fullname: "Please enter your fullname", > > company: "Please enter a company name", > > phone: "Please enter a phone number", > > email: "Please enter a valid email address" > > } > > > }); > > > });
[jQuery] Submitting after Validation
I'm trying to create a contact form using Jquery Validation and Ajax Submit. I'm having a problem figuring out the best way to submit the results to a php file. Below is a break down of my validation code. $().ready(function(){ $("#signupForm").validate({ rules: { fullname: "required", company: "required", phone: "required", email: { required: true, email: true } }, messages: { fullname: "Please enter your fullname", company: "Please enter a company name", phone: "Please enter a phone number", email: "Please enter a valid email address" } }); });