0

I have a custom site using PHP mail() as the contact forms delivery system. People are able to contact me using this form and everything has appeared to work for the past year (until now).

Someone tried contacting me with a Safari browser but I recieve nothing in my mailbox. I've tested all browsers work on my Windows computer and they were all able to send forms correctly. I also tested Safari using a live tester here: https://crossbrowsertesting.com/live-testing and it also correctly sent me an email to my inbox.

Still, a person using Safari on their Mac laptop is still unable to send me emails.

I am using a .php file and a .js file for people to send me emails. Everything is very simple and straight forward. Please see here:

https://codepaste.net/g966d6

Would anyone know what could cause this to not work? I've been banging my head against the keyboard the past several hours trying to troubleshoot this.

  • Include your code in your question here, not in a link. Questions seeking debugging help ("**why isn't this code working?**") must include the desired behavior, a *specific problem or error* and *the shortest code necessary* to reproduce it **in the question itself**. Questions without **a clear problem statement** are not useful to other readers. See: [How to create a Minimal, Complete, and Verifiable example.](http://stackoverflow.com/help/mcve) – elixenide Mar 16 '17 at 05:37
  • Obviously there could be any number of possibilities, but have you checked whether there may be an issue with the sender’s IP address. Sometimes the sender is sending from a local IP address which may be aggressively filtered. I also note, with dismay, that you don’t appear to doing any data validation in PHP. JavaScript is _not_ a substitute for good server-sided validation. Finally, have your checked your own mail logs to see whether it’s getting to your server? – Manngo Mar 16 '17 at 05:47

1 Answers1

0

some browsers have strict protocols while interpreting the code and your js & php files are correct but in your html page is coming before look at the second last elsement try correcting it.........

  <section id="form">   
    <div class="container"> 
            <form id="contact_form" method="post" class="form" onsubmit="return confirm('Successfully submitted!');">
            <div class="contact-form">
                    <div class="row"> 
                        <div class="col-md-6 col-sm-6 form-group ">
                            <input class="form-control" id="name" name="name" placeholder="Full name " type="text" required>
                        </div>
                        <div class="col-md-6 col-sm-6 form-group ">
                            <input class="form-control" id="email" name="email" placeholder="Email" type="text" required>
                        </div>
                    </div>
                    <div class="row">
                        <div class="col-md-6 col-sm-6  form-group ">
                            <input class="form-control" id="city" name="city" placeholder="City" type="text" required>
                        </div>
                        <div class="col-md-6 col-sm-6 form-group">
                            <input class="form-control" id="province" name="province" placeholder="Province" type="text" required>
                        </div>
                    </div>
                    <div class="row">
                        <div class="col-md-12">
                            <textarea class ="form-control" placeholder ="ISBNs with book conditions. One ISBN per line." id="message" name="message" required></textarea>
                        </div>
                    </div>
                    <div class="row mt20">
                        <div class="col-md-12 form-group">
                            <button id="submit_btn" name="submit_btn" type="submit" value="submit_btn" class="btn btn-outline btn-primary btn-icon pull-right btn-lg btn-rounded">Submit
                                <span class="fa fa-chevron-right icon-with-btn"></span>
                            </button>
                        </div>
                    </div>
                </form>
        </div>  // this div should be before </form>
    </div>
</section>
Mohit_
  • 49
  • 1
  • 7