Hello guys! I want something like this: A form: my email(hidden in the script) To: (a text bar to enter email) Message: (body message) and a send button. What it do, people enter email and press send button. This sends email to the entered email from myemail address. thanks in advance..
Most basic example ever: mail($_POST['recipient'], 'Subject goes here', $_POTS['message'], 'From: You <you@example.com>'); PHP: www.php.net/function.mail I guess you can make the form yourself?
yes sure i can. Thank you so much for script. Let me do my own experiments now. Actually trying to create an sms system for me so people wont need java applet to send free sms from my site. Hope u get. THanks again. If i need a help, i will ask again. + for u. Edit:Well this worked I need something, i want to show sent confirmation text, a bit confused how to do it. So, any help?
if(mail($_POST['recipient'], 'Subject goes here', $_POTS['message'], 'From: You <you@example.com>')){ echo "Mail Successfully sent."; }else{ echo "Mail could not be sent."; } PHP:
The above is vulnerable to header injection...you need to validate the e-mail address field before sending the message.
and how can i do that? i just know a little bit in php. making variables and using get commands lol so plz help.