Dear Reader,
This is the code I use to output a field from a MySQL database:
<?php
$display_title = mysql_query("SELECT html FROM legal WHERE pageid=$pageid")
or die ("MySQL Error - Please report this to the webmaster");
if (mysql_num_rows($display_title) > 0)
{
while ($row = mysql_fetch_array($display_title))
{
$legal = $row["html"];
echo $legal;
};
}
else
{
echo("No Such Page");
}
?>
Now, how do I get this code to output the data using a certain CSS class?