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

  • Home
  • SEARCH
  • 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 8282313
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 8, 20262026-06-08T10:19:49+00:00 2026-06-08T10:19:49+00:00

I only need a very basic/simple form to send the email but it doesn’t

  • 0

I only need a very basic/simple form to send the email but it doesn’t seem to work and I’m not sure why? I know the code isn’t very advanced and probably looking ‘ugly’ but it will do for what I ‘need’ it for

if (isset($_POST['email']))
{

    $full_name = $_POST['fullName'];
    $phone = $_POST['phoneNumber'];
    $adMessage = $_POST['emailMessage'];

    //send email
    $to = "info@lalalalala.co.uk";
    $from = $_POST['emailAddress'];
    $subject = $_POST['emailSubject'];

    $message = "Full name: " . $full_name . "\n";
    $message .= "Phone number: " . $phone . "\n";
    $message .= "Email Address: " . $from . "\n";
    $message .= "Additional Message: " . $adMessage;


    $headers = "From:" . $full_name;
    mail($to, $subject, $message, $headers);
}

HTML

<form action='' method='post'>

    <fieldset><label id="fullName">Full Name</label>
    <input type="text" name="fullName" value="Please Enter Your Full Name" onclick="this.value=''"  /></fieldset>

    <fieldset><label id="emailAddress">Email Address</label>
    <input type="text" name="emailAddress" value="Please Enter Your Email Address" onclick="this.value=''"  /></fieldset>

    <fieldset><label id="phoneNumber">Phone Number</label>
    <input type="text" name="phoneNumber" value="Please Enter Your Phone Number" onclick="this.value=''"  /></fieldset>

    <fieldset><label id="emailSubject">Email Subject</label>
    <input type="text" name="emailSubject" value="Please Enter Email Subject" onclick="this.value=''"  /></fieldset>

    <fieldset><label id="emailMessage">Your Message</label>
    <textarea cols="10" rows="20" name="emailMessage" onclick="this.value=''" >Please Enter Your Message</textarea></fieldset>

    <fieldset><input type="image" src="images/submit.png" id="submit" onclick="show_alert();" /></fieldset>
</form>

Thank you 🙂

  • 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-08T10:19:51+00:00Added an answer on June 8, 2026 at 10:19 am

    You haven’t set any input named email. Your first conditional won’t be evaluated to true, so you skip everything that follows.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I need a very simple menu which probably contains only one or two items:
Maybe this is very basic, but I am all confused. I have a simple
I have a very basic understanding of shell scripting, but what I need to
I just started out with jQuery and really only need it for some very
I need to deploy only the referenced classes in a very limited environment as
This is WebKit browsers specific (meaning that I only need to make it work
Imagine the following: you read in a string with scanf() but you only need
I am a very basic user and do not know much about commands used
I need to write a very basic command interpreter on a micro controller that
This must be something very basic. I'm not familiar with the syntax, and this

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.