ohsnyder
-
Posts
3 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Posts posted by ohsnyder
-
-
Thank you very much! Removed the single quotes and it works fine now.You have lname in quotes, remove the quotes. You are telling it to sort by the text "lname" (which is the same for every record) instead of the lname field. -
an someone tell me why this code isNOT sorting the lname output listing ? <?php include("/home/mdwvo/public_html/aabees.org/password_protect.php"); ?> <?php $con = mysql_connect("localhost","mdwvo_aaba","pwpwpwpwpw");if (!$con) { die('Could not connect: ' . mysql_error()); } mysql_select_db("mdwvo_aaba", $con); $result = mysql_query("SELECT * FROM members WHERE deleted = 'Yes' ORDER BY 'lname' "); Echo "<table size=50%>"; while($row = mysql_fetch_array($result)) { Echo "<tr><td>".$row['id'] . "</td></tr> <tr><td>".$row['fname']." ".$row['lname']."</td><td align=left> Date Joined - ".$row['joined'] . "</td></tr> <tr><td>".$row['street'] . "</td><td align=left> Dues Paid Through - ".$row['paid'] . "</td></tr> <tr><td align=left>".$row['city'] . ", ".$row['state'] . " ".$row['zip'] . "</td><td align=left> Phone - ".$row['phone'] . "</td></tr> <tr><td> </td><td align=left> Email - ".$row['email'] . "</td></tr>"; } Echo "</table>"; mysql_close($con);?>
w3.css form to the php action page
in CSS
Posted
I am trying to use the example contact form in the w3-ccs examples. The submit form processes but there is no data sent with the form. Can some one set me on the right path on how to get the data into php processing page?
php process code:
$EmailFrom = "email@greengardensdesign.com";
$EmailTo = "email@greengardensdesign.com";
$Subject = "Possible New Job";
$Name = Trim(stripslashes($_POST['Name']));
$Address = Trim(stripslashes($_POST['Address']));
$City = Trim(stripslashes($_POST['City']));
$Email = Trim(stripslashes($_POST['Email']));
$Phone = Trim(stripslashes($_POST['Phone']));
$Message = Trim(stripslashes($_POST['Message']));
$validationOK=true;
if (!$validationOK) {
print "<meta http-equiv=\"refresh\" content=\"0;URL=error.htm\">";
exit;
}
$Body = "";
$Body .= "Name: ";
$Body .= $Name;
$Body .= "\n";
$Body .= "Address: ";
$Body .= $Address;
$Body .= "\n";
$Body .= "City: ";
$Body .= $City;
$Body .= "\n";
$Body .= "Email: ";
$Body .= $Email;
$Body .= "\n";
$Body .= "Phone: ";
$Body .= $Phone;
$Body .= "\n";
$Body .= "Message: ";
$Body .= $Message;
$Body .= "\n";
$success = mail($EmailTo, $Subject, $Body, "From: <$EmailFrom>");
if ($success){
print "<meta http-equiv=\"refresh\" content=\"0;URL=contactthanks.php\">";
}
else{
print "<meta http-equiv=\"refresh\" content=\"0;URL=error.htm\">";
}
?>
<form action="/contactengine.php" method="post" class="w3-container w3-card-4 w3-light-grey w3-text-blue w3-margin">
<h2 class="w3-center">Contact Us</h2>
<div class="w3-row w3-section">
<div class="w3-col" style="width:50px"><i class="w3-xxlarge fa fa-user"></i></div>
<div class="w3-rest">
<input class="w3-input w3-border" name="Name" type="text" placeholder="Full Name">
</div>
</div>
<div class="w3-col" style="width:50px"><i class="w3-xxlarge fa fa-car"></i></div>
<div class="w3-rest">
<input class="w3-input w3-border" name="Address" type="text" placeholder="Street Address">
</div>
</div>
<div class="w3-col" style="width:50px"><i class="w3-xxlarge fa fa-car"></i></div>
<div class="w3-rest">
<input class="w3-input w3-border" name="City" type="text" placeholder="City and State">
</div>
</div>
<div class="w3-col" style="width:50px"><i class="w3-xxlarge fa fa-envelope-o"></i></div>
<div class="w3-rest">
<input class="w3-input w3-border" name="Email" type="text" placeholder="Email">
</div>
</div>
<div class="w3-col" style="width:50px"><i class="w3-xxlarge fa fa-phone"></i></div>
<div class="w3-rest">
<input class="w3-input w3-border" name="Phone" type="text" placeholder="Phone">
</div>
</div>
<div class="w3-col" style="width:50px"><i class="w3-xxlarge fa fa-pencil"></i></div>
<div class="w3-rest">
<input class="w3-input w3-border" name="Message" type="text" placeholder="Message">
</div>
</div>