Jump to content

PHP Mail


uaintgotthisid

Recommended Posts

Hi all,I'm clearly a new guy here, so forgive any ignorance.I've followed the PHP mail example shown on w3schools here: http://www.w3schools.com/php/php_secure_mail.aspHowever, when I test the page I notice that there are extra characters after the form (the characters close the php echo and then close the } and then the php i.e. ""; } ?> "). It seems that the echo function won't shut up and is babbling out all the PHP at the end. If you want an example of what I'm talking about just copy and paste the example they show. I was trying the one without injections but it seems the others do similar things. I've seen this on quite a lot of websites, so it's possibly a common problem.Thanks in advance.

Link to comment
Share on other sites

Follow this tutorial (even though it's for earlier versions of everything, the instructions remain the same), and once you finish the "test PHP" step, try the W3Schools example again.

Link to comment
Share on other sites

The PHP code is correct, it's not going to show the characters at the end if PHP is working on the server. To test that yourself, open your page in the browser and view the source code. If you see any PHP code in there, anything that is not HTML, then PHP isn't being executed. When you open the page in the browser you should only see HTML code, no PHP. PHP code doesn't get sent to the browser.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...