html - simple PHP contact form not sending one input form value -


as title says, have simple php contact form 1 of input values not being post rest of values.

it part of div hidden jquery until value clicked, value part of same div post, unsure if causing problem.

the attending , song_choice inputs hidden jquery until accepts radio button clicked. attending input 1 input not post. unsure issue may be, must simple missing googling, cannot figure out. below code:

html:

<form action="email_form.php" method="post">     <h5 class="rsvp-text">please respond <strong>august 15, 2015</strong></h5>     <input class="rsvp-input" type="text" name="name" placeholder="please enter first & last name:" ><br>     <input type="radio" class="rsvp-radio" id="accepts-button"  value="accepts pleasure" name="rsvp_response"> accepts pleasure     <input type="radio" class="rsvp-radio" id="declines-button" value="declines regret" name="rsvp_response"> declines regret<br>         <div id="accepts-qs">             number attending:             <input name="attending" type="text" placeholder="enter number:"><br>             <p><em>"while love see children run & play,</br> adults kind of day."</em></p>             promise dance if play:<br>             <textarea class="rsvp-input" type="text" name="song_choice" placeholder="song title , artist:"></textarea></br>         </div>     <input class="rsvp-button" type="submit" value="send"> </form> 

php:

/* e-mail recipient & subject */ $myemail = "email@email.com"; $subject = "wedding rsvp";  /* rsvp responses */ $name = $_post['name']; $rsvp_response = $_post['rsvp_response']; $attending = $_post['$attending']; $song_choice = $_post['song_choice'];  /* email message*/ $message = "from: $name\nresponse: $rsvp_response\nnumber attending: $attending\nsong choice: $song_choice";  /* mail function send email */ mail($myemail, $subject, $message);  /* redirect visitor home page */ header('location: index.html'); exit();  ?> 

change $_post['$attending'] $_post['attending'] , believe should work.


Popular posts from this blog

php - How should I create my API for mobile applications (Needs Authentication) -

5 Reasons to Blog Anonymously (and 5 Reasons Not To)

Google AdWords and AdSense - A Dynamic Small Business Marketing Duo