Hello. I have a problem again ... I want to add some CSS to PHP, and I have external file for CSS. Why some elements work, and most element don't work with PHP/CSS files?
Here are examples:
CSS working elements:
.maintable {
width: 90%;
border-style: solid;
border-width: 1px;
border-color: #000000;
background: #FFFFCC;
}
.headline {
background: #009999;
color: #FFFFFF;
font-size: 12px;
font-family: helvetica, sans-serif;
text-align: center;
}
.mainrow {
background: #FFFFCC;
color: #000000;
font-size: 12px;
font-family: helvetica, sans-serif;
text-align: left;
}
input {
background: #FFFFCC;
border: 1px solid #009999;
color: #000000;
size: 12px;
font-size: 11px;
font-family: helvetica, sans-serif;
}
a, a:visited, a:active {
color: #000000;
font-size: 12px;
font-family: helvetica, sans-serif;
text-decoration: none
}
a: hover {
color: #000000;
font-size: 12px;
font-family: helvetica, sans-serif;
text-decoration: underline;
}
.mainrow2 {
background: #FFFFCC;
color: #000000;
font-size: 12px;
font-family: helvetica, sans-serif;
text-align: center;
}
.mainrow3 {
background: #FFFFFF;
color: #000000;
font-size: 12px;
font-family: helvetica, sans-serif;
text-align: center;
}
And here are elements that do not work:
.main {
width: 90%;
border-style: solid;
border-width: 1px;
border-color: #000000;
background: #FFFFFF;
}
.forumtable {
width: 100%;
border-style: solid;
border-width: 1px;
border-color: #FFFFFF;
}
.forumrow {
background: #FFFFCC;
color: #000000;
font-size: 12px;
font-family: helvetica, sans-serif;
text-align: left;
}
And here is PHP page:
if ($pid == '')
{
$topic = mysql_query("SELECT * FROM cst_forum_topics") or die (mysql_error());
WHILE ($topic2 = mysql_fetch_array($topic))
{
print '<table class="maintable">';
print '<tr class="headline2">';
print '<td>Topic Title: '.$topic2[topic].'</td>';
print '</tr>';
print '<tr class="forumrow">';
print '<td>By: '.$topic2[starter].', '.$topic2[date].'</td>';
print '</tr>';
print '</table>';
print '<br/>';
}
}
Element .maintable work perfectly just like .headline. However, .headline2, .forumrow do not work for me. Why ?
Thank you for any help ...