-1
我對PHP沒有太多的經驗 - 我使用了表單生成器來創建此表單。問題在於表單發送數百封空白電子郵件。任何人都可以幫助我解決它嗎?以下是PHP代碼:發送空白郵件的PHP表單
<?php
$where_form_is="http://".$_SERVER['SERVER_NAME'].strrev(strstr(strrev($_SERVER['PHP_SELF']),"/"));
mail("[email protected]","MESSAGE: website","
Someone has submitted a message from your website! Huzzah!
--------------------------------------------------------------------------------
CONTACT INFO:
" . $_POST['field_1'] . "
" . $_POST['field_2'] . "
MESSAGE:
" . $_POST['field_3'] . "
--------------------------------------------------------------------------------
Also you're a stud.
");
header("Refresh: 0;url=http://www.blah.com/thanks.html");
?>
確保你的HTML表單方法是POST,或者在PHP上使用$ _GET或$ _REQUEST,$ _REQUEST與($ _POST || $ _GET)的值相同, – GTSouza