Click here to Skip to main content
Rate this: bad
good
Please Sign up or sign in to vote.
See more: Javascript HTML Ajax , +
Hello,
I need some help, I am creating a webpage and want to a 'contact' form of my webpage the user can leave a message but this message to forward to an email address, I want to use ajax so that the webpage won't reload to another and to display a success message, any tutorial, webpage link welcome.
 
Thank you
Kyriakos
 
Don't want to mess with php if possible
Posted 4-Nov-12 22:51pm
Comments
aspnet_regiis -i at 5-Nov-12 3:55am
   
You cannot send email via javascript , ajax or jQuery. You need to use server side logic to send email.
Ankur\m/ at 5-Nov-12 4:04am
   
why not? send an ajax request using javascript/jQuery which will send mail to the passed address from the server.
aspnet_regiis -i at 5-Nov-12 4:35am
   
I am talking about sending 'email' via javascript .Not about sending 'request' via javascript
Ankur\m/ at 5-Nov-12 5:02am
   
And I am also talking about sending email using javascript/jQuery. It is very much possible and is done by sending an ajax request to server asking it to do so.
See how I used javascript to send email.
aspnet_regiis -i at 5-Nov-12 6:14am
   
See ? Where ????
n.podbielski at 5-Nov-12 6:37am
   
++ :)
Member 3892343 at 5-Nov-12 5:38am
   
So can be done? any tutorial or code?
n.podbielski at 5-Nov-12 6:40am
   
It is not possible. HTTP is HTTP. SMTP is SMTP. Both work over TCP, that's all.
You have to mess with PHP or other server language.
aspnet_regiis -i at 5-Nov-12 6:43am
   
:)
Member 3892343 at 5-Nov-12 8:05am
   
any tutorial with php?
ryanb31 at 5-Nov-12 9:00am
   
Use the .ajax() call in jQuery to call webservice on your server which actually sends the email.
Mathlab at 5-Nov-12 17:04pm
   
You can use an update panel for that, add your script manager and all the items to an update panel and you get refreshes with not flashing page

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
0 OriginalGriff 428
1 Maciej Los 249
2 BillWoodruff 199
3 /\jmot 180
4 Suraj Sahoo | Coding Passion 150
0 OriginalGriff 8,484
1 Sergey Alexandrovich Kryukov 7,407
2 DamithSL 5,639
3 Maciej Los 5,159
4 Manas Bhardwaj 4,986


Advertise | Privacy | Mobile
Web03 | 2.8.1411023.1 | Last Updated 5 Nov 2012
Copyright © CodeProject, 1999-2014
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100