Alright, I looked though the read me's, went over the FAQ's... Think it is time to post...
So, this lump is what I got from going though google and piecing together the bits that looked good.
<?php
$db_host = "****";
$db_user = "****";
$db_pwd = "****";
$database = "****";
$table = "****";
$query = "SELECT * FROM {$table}";
$conn = mysqli_connect($db_host, $db_user, $db_pwd, $database);
$result = mysqli_query($conn,$query) or trigger_error($query . ' - has encountered an error at:<br />' . mysqli_error($conn));
$fields = mysqli_fetch_fields($conn);
$field_count = mysqli_num_fields($conn);
echo '<table border="1" style="width:100%">' . "\n" . '<tr>';
$i = 0;
foreach($fields as $field)
{
if(++$i == 1) {
echo '<th colspan="' . $field_count . '">' . $field->table . '</th></tr><tr>';
}
echo "\n" . '<th>' . $field->name . '</th>';
}
echo '</tr>';
while($row = mysqli_fetch_row($result)) {
echo '<tr><td>' . implode('</td><td>' , $row) . '</td></tr>';
}
echo '</table>';
?>
The goal is to display the table and conditionally format the contents.
Let's forget about the conditional part (thinking if/than but don't know how I'm going to do that yet) and focus on the key problem: displaying the table.
I have tested this code. It works...to a point. it displays the table and its contents but no headers. I know my issue is in line 20 and 22 but I can not for the life of me figure it out. If it is stupidly easy (for you) please remember that I am not a coder. At best I am a scripter when it comes to linux. I am over my head on this stuff.
Thank you all for any help you can give me