javascript contact form?

Messages
1,756
Edit My Images
No
right, currently redoing my website, the current 'old' design uses a php form but wondering about using a javascript (or ajax?) one instead to make it a bit neater and streamlined. php is ok but bit clunky, needs a couple of further pages of code to go with the form as well, so just want something that fits into one page...there are some I've found as wordpress plugins but i'm not using wordpress to run the site (though I plan on having a blog page off to the side, daily going's on etc)...i had a google too but :thinking:
so, anyone know where I can pick up a source code/tutorial how to implement something like that, and stick it into a page?
 
Interesting as I use this. Will have to keep an eye on this thread to see what folks come up with.
 
You will be able to use javascript or ajax for the frontend of the page but you will still need a php/asp/cgi/perl script behind it to process the form and do the dirty work.
 
Javascript only is not recommended. If people have it turned off, then they wont be able to use the form. You will need PHP to back up what javascript there is, plus do the mail send (or another server side client).

You can use just the one page using a mixture of PHP and Javascript (Jquery library is your best bet) for the contact form very easily. PHP to do all the form checking (on the same page) and mail send, and Javascript/Ajax for refreshing just the contact form area with the thank you message.

Plus, if anything, Javascript is usually more clunky than PHP ;)

:)
 
ah, cheers for the info. yes, on the above linked php form you need to write a separate 'form sent' page, i was hoping by using a javascript it would remove that requirement and basically have it all essntially in the same page without reloading etc to another page.
i'm not a web geek but sort of get the idea, will have to get my head round all this coding stuff then and see what I can make into the new design I'm working on.
 
I would leave it with a PHP form personally. Any type of form script will pretty much do the same thing.
 
Back
Top