<?php
/*
if (isset($_POST['submit'])) {
// BRACE OPEN To see if submitted
// isset($_POST['radio_name'])
$fav = $_POST["favorite"];
if (!($fav == '')) {
// BRACE OPEN to see IF they've actually picked a favorite
$fh = fopen ( "cartoon_vote.txt", 'a' ) ;
fWrite( $fh, "fav->".$fav."\n");
$ip = getenv("REMOTE_ADDR");
fWrite( $fh, $ip."\n");
$client = $_SERVER['HTTP_USER_AGENT'];
fwrite( $fh, "Operating system: ".explode(";",$client)[1]."\n");
fwrite( $fh, "Browser: ".end(explode(" ",$client))."\n");
date_default_timezone_set('America/New_York');
$date = date('Y-m-d H:i:s');
fwrite( $fh, "date/time->". $date. "\n");
fclose ($fh) ;
// the message
$msg = "here is a new *mail* from ps.com";
// send email
mail("peter@peter-sohn.com","cartoon_vote.txt",$msg);
ECHO "THANKS FOR VOTING" ;
exit;
} // Closing BRACE because they HAVE chosen a favorite
elseif (isset($_POST['submit'])) {
echo "<h1>Please complete the form before submitting!</h1>";
}
} // Closing BRACE for an if to segregate SELF-SUBMITS
*/
?>
<html>
<head>
<style> a img { border: 2px blue solid; padding: 5px; }
table {
border-collapse: collapse;
}
td, th {
text-align: left;
padding: 8px;
}
tr:nth-child(even) {
background-color: #dddddd;
}
<!--
.test{
border-right: 2px solid;
}
-->
</style>
</head>
<body>
<!-- span style='line-height: 0.1px; padding-bottom: 40px;' -->
<table width="99%"><tr><td width="6%"> </td> <td class="test" width= "93%">
<img src = "cartoon.jpg" width = 443><br> <br></td><!-- td width="1%"> </td><td width= "39%"><br>
<img src="cartoon.jpg" width = 433></td><td width="23%"> </td --></tr></table>
<hr><br>
<!-- form method="post" action="index.php">
<p><h2>Poll – Which cartoon (pick 1, please) is funnier?</h2></p>
<input type="radio" id="No1" name="favorite" value="Left">
<label for="No1">LEFT ("Roach Motel")</label><br>
<input type="radio" id="No2" name="favorite" value="Right">
<label for="No2">RIGHT ("OK, boomer")</label><br>
<br>
<div><button name="submit" type="submit">Submit</button></div>
</form -->
<h2 style="color: red;">To contact me, please use this form.</h2><br>
<form name="afm_form_aac2f538" id="afm_form_aac2f538" action="https://secure.mailjol.net/allforms/u/aac2f538.php" method="POST" style="margin: 0px">
<table border="0" cellpadding="6" cellspacing="0" style="text-align: left; border: 4px solid #7090B0; border-collapse: collapse" width="400" bgcolor="#F0F0F0"><tr>
<td colspan="2" bgcolor="#7090B0" style="font-size: 14px; font-family: Verdana; color: #FFFFFF; font-weight: bold; padding: 4px">Contact Form</td>
</tr><tr>
<td colspan="2" style="padding: 8px; font-size:11px; font-family: Verdana; color: #000000">Questions marked by * are required.</td>
</tr><tr>
<td width="1%" style="font-size: 30px; font-family: Verdana; color: #C0C0C0; font-weight: bold; padding-left: 20px" valign="top" align="right">1.</td>
<td width="99%" style="font-size: 11px; font-family: Verdana; font-weight: bold; padding-right: 20px; color: #000000">Name: *<br><input type="Text" name="Name:" size="65" style="font-size: 11px; font-family: Verdana"></td>
</tr><tr>
<td width="1%" style="font-size: 30px; font-family: Verdana; color: #C0C0C0; font-weight: bold; padding-left: 20px" valign="top" align="right">2.</td>
<td width="99%" style="font-size: 11px; font-family: Verdana; font-weight: bold; padding-right: 20px; color: #000000">Email: *<br><input type="Text" name="Email:" size="65" style="font-size: 11px; font-family: Verdana"></td>
</tr><tr>
<td width="1%" style="font-size: 30px; font-family: Verdana; color: #C0C0C0; font-weight: bold; padding-left: 20px" valign="top" align="right">3.</td>
<td width="99%" style="font-size: 11px; font-family: Verdana; font-weight: bold; padding-right: 20px; color: #000000">Message: *<br><textarea rows="4" cols="65" style="font-size: 11px; font-family: Verdana" name="Message:"></textarea></td>
</tr><tr>
<td colspan="2" align="center" style="padding: 8px"><input type="submit" name="submit" value="Submit" style="font-size: 11px; font-family: Verdana"> <input type="reset" name="reset" value="Reset" style="font-size: 11px; font-family: Verdana"></td>
</tr>
</table></form>
</body></html>