Skip to content

Instantly share code, notes, and snippets.

@pastranastevenaz
Created September 13, 2019 04:16
Show Gist options
  • Select an option

  • Save pastranastevenaz/8573329a3bee15dc1eb91fbbd5027a79 to your computer and use it in GitHub Desktop.

Select an option

Save pastranastevenaz/8573329a3bee15dc1eb91fbbd5027a79 to your computer and use it in GitHub Desktop.
PHP simple mail form
<?php
if ($_POST[submitted])
{
echo "Process form";
}
else
{
echo <<< _ENDOFFORM_
<form method="post" action="$_SERVER[SCRIPT_NAME]">
<label for="fname">First Name</label>
<input type="text" name="first_name" id="fname" /><br />
<input type="submit" name="submitted" />
</form>
_ENDOFFORM_;
}
?>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment