Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8387613
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 9, 20262026-06-09T18:15:40+00:00 2026-06-09T18:15:40+00:00

I created a form which works in Chrome and IE, but not Firefox. On

  • 0

I created a form which works in Chrome and IE, but not Firefox. On submit, it simply goes to a blank screen with the URL of my PHP file, sendContact.php.

Here’s the markup:

<form action="script/sendContact.php" method="post" class="contactForm">
  <div class="textBoxDivs">
    <label>Name</label>
    <br />
    <input type="text" id="name" name="name" size="40" class="textField"/>
  </div>
  <div class="textBoxDivs">
    <label>Phone</label>
    <br />
    <input type="text" id="phone" name="phone" size="40"class="textField"/>
  </div>
  <div class="textBoxDivs">
    <label>Email</label>
    <br />
    <input type="text" id="email" name="email" size="40"class="textField"/>
  </div>
  <div class="textArea">
    <label>Please describe what services you will require and your proposed budget.</label>
    <br />
    <textarea id="message" cols="40" rows="7" name="message" class="textAreaField">    </textarea>
  </div>
  <div class="formButtonDiv">
    <input type="submit" value="submit" class="formBut"/>
    <input type="reset" value="reset" class="formBut" />
  </div>
</form>

and the PHP is as follows:

$name       = $_POST['name'];
$email      = $_POST['email'];
$message    = $_POST['message'];
$phone      = $_POST['phone'];
$formcontent= "From: $name \n Email: $email \n Phone: $phone \n Message: $message";
$recipient  = "al@gmail.com";
$subject    = "Contact Form";
$mailheader = "From: $userEmail \r\n";

if (mail($recipient, $subject, $formcontent, $mailheader, $email))
{
  header ("Location: thankYou.html");
} else {
  echo "mail was not sent";
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-09T18:15:42+00:00Added an answer on June 9, 2026 at 6:15 pm

    I’ve tried on Firefox right now, and every thing went fine. By the way, looking at your php code, you should check if the form is ok before sending it. I’ve tried with empty field and I guess you just receive a mail from nobody..

    Try something like:

    $name       = trim($_POST['name']);
    $email      = trim($_POST['email']);
    $message    = trim($_POST['message']);
    $phone      = trim($_POST['phone']);
    
    $formcontent= "From: $name \n Email: $email \n Phone: $phone \n Message: $message";
    $recipient  = "alverdeja88@gmail.com";
    $subject    = "Contact Form";
    $mailheader = "From: $userEmail \r\n";
    
    if (!empty($name) 
      && !empty($email)
      && !empty($message)
      && mail($recipient, $subject, $formcontent, $mailheader, $email))
    {
      header ("Location: http://www.dukecitygrafx.com/thankYou.html");
    }
    else
    {
      echo "mail was not sent";
    }
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have some jQuery code which works great in Firefox and Chrome, but does
I made a certain piece of functionality which works perfectly on Chrome, but not
I've created a form which works fine, but when I put it in a
I have created a PHP form which requires the user to select a postcode
I have a form which I created using PHP (something I do no understand
My code (Below) works in Internet Explorer, but not in Chrome, Safari or Mozilla
I created an upload form for images, which works properly and saves files in
I have created one jsp form which contains the username textfield. On the click
I've created a form on which I load several questions from a database, the
I have created a form on which two components are present, button and progressbar

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.