using php to send mail through contact form
<p>I have this function and after doing some research i'm still not being able to find out why this isn't working
I am new to PHP and would like some help. thank you.</p>

<blockquote>
  <p>sendemail.php</p>
</blockquote>

<pre><code>&lt;?php
    header('Content-type: application/json');
    $status = array(
        'type'=&gt;'success',
        'message'=&gt;'Mail Sent. Thank you , we will contact you shortly. '
    );

    $name = @trim(stripslashes($_POST['name'])); 
    $email = @trim(stripslashes($_POST['email'])); 
    $subject = @trim(stripslashes($_POST['subject'])); 
    $message = @trim(stripslashes($_POST['message'])); 

    $email_from = $email;
    $email_to = 'help@addonevents.in';//replace with your email

    $body = 'Name: ' . $name . "\n\n" . 'Email: ' . $email . "\n\n" . 'Subject: ' . $subject . "\n\n" . 'Message: ' . $message;

    mail($email_to, $subject, $body, 'From: &lt;'.$email_from.'&gt;');
    echo json_encode($status);
    die;
</code></pre>

<blockquote>
  <p>My form</p>
</blockquote>

<pre><code>&lt;form name="contact-form" method="POST" action="sendemail.php"&gt;
                &lt;label&gt;Name *&lt;/label&gt;
               &lt;input type="text" name="name" required="required"&gt;
                &lt;label&gt;Email *&lt;/label&gt;
                &lt;input type="email" name="email" required="required"&gt;
                &lt;label&gt;Phone&lt;/label&gt;
                &lt;input type="number"&gt;
                 &lt;label&gt;Subject *&lt;/label&gt;
                &lt;input type="text" name="subject" required="required"&gt;
                 &lt;label&gt;Message *&lt;/label&gt;
                 &lt;textarea name="message"  required="required" rows="8"&gt;&lt;/textarea&gt;
                 &lt;button type="submit" name="submit" required="required"&gt;Submit Message&lt;/button&gt;
&lt;/form&gt; 
</code></pre>

<p>can anyone help? I am getting the success message but no mail to my inbox
Thank you.</p>