Created
November 15, 2020 15:58
-
-
Save alfintechcomputer/0d63cc27cdaadde0294be0785ac6e2d6 to your computer and use it in GitHub Desktop.
HTML Forms using PHP
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<link href="css/bootstrap.min.css" rel="stylesheet"> | |
<script src="js/respond.js"></script> | |
<script src="http://code.jquery.com/jquery-latest.min.js"></script> | |
<script src="js/bootstrap.min.js"></script> | |
</head> | |
<body> | |
<?php | |
if(isset($_POST['submit'])) { | |
echo 'Nice Form Submission!<br>'; | |
} else { | |
echo 'Stop trying to hack the form fool!'; | |
exit; | |
} | |
$website = isset($_POST['website']) ? ($_POST['website']) : 'http://twitter.com' ; | |
$category = isset($_POST['category']) ? ($_POST['category']) : 'Social' ; | |
echo "Hi bud, thanks for submitting <b>$website</b> to the <b>$category</b> category."; | |
?> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment