<style type='text/css'>
.css
{
border:2px grey solid;
}
</style>
<script type='text/javascript' src='about/about.js'>
</script>
<h3 style='margin:0px;'>CSS T<small>HEMER</small> v1.0</h3>
<small>
» <a href="about/css1.php" onclick="NewWindow(this.href,'name','400','580','yes');return false;" class='under'>About CT v1.0</a>
</small>
<?php
$login=$_SESSION['login'];
include("db.php");
$dbh=mysql_connect ($host,$user,$pass) or die ('MySQL Error: ' . mysql_error());
mysql_select_db ($table);
$sql="SELECT * FROM CSS_TEMP WHERE Username='$login';";
$rs=mysql_query($sql,$dbh);
$row=mysql_fetch_array($rs);
$text=$row['text'];
$background=$row['background'];
$activelink=$row['activelink'];
$link=$row['link'];
$vlink=$row['vlink'];
$h1=$row['h1'];
$h2=$row['h2'];
mysql_close($dbh);
?>
<br/><br/>
<table summary='css_all' border='0'>
<tr>
<td>
<form method='post' action='?id=update_css'>
<table summary='css' border='0'>
<tr>
<th colspan='2'>General</th>
<!--Spacer bar-->
<td/>
<td rowspan='11' width='25px'/>
<td rowspan='11' style='background-color:#000000; width:2px;'/>
<td rowspan='11' width='10px'/>
<!--//Spacer-->
</tr>
<tr>
<td>
Body Text
</td>
<td align='center'>
<?php echo "<div id='div_body' class='css' style='background-color: #$text; width: 20px; height: 20px;'></div>"?></td>
<td><a href='?id=change_css&div=text' class='under'>Change</a>
</td>
</tr>
<tr>
<td>
Background Color
</td>
<td align='center'>
<?php echo "<div id='div_background' class='css' style='background-color: #$background; width: 20px; height: 20px;'></div>"?></td>
<td><a href='?id=change_css&div=background' class='under'>Change</a>
</td>
</tr>
<tr>
<th colspan='2'>Links</th>
</tr>
<tr>
<td>
General Links
</td>
<td align='center'>
<?php echo "<div id='div_link' class='css' style='background-color: #$link; width: 20px; height: 20px;'></div>"?></td>
<td><a href='?id=change_css&div=link' class='under'>Change</a>
</td>
</tr>
<tr>
<td>
Active Links
</td>
<td align='center'>
<?php echo "<div id='div_alink' class='css' style='background-color: #$activelink; width: 20px; height: 20px;'></div>"?></td>
<td><a href='?id=change_css&div=activelink' class='under'>Change</a>
</td>
</tr>
<tr>
<td>
Visited Links
</td>
<td align='center'>
<?php echo "<div id='div_vlink' class='css' style='background-color: #$vlink; width: 20px; height: 20px;'></div>"?></td>
<td><a href='?id=change_css&div=vlink' class='under'>Change</a>
</td>
</tr>
<tr>
<th colspan='2'>Headers</th>
<tr>
<tr>
<td>
H1
</td>
<td align='center'>
<?php echo "<div id='div_h1' class='css' style='background-color: #$h1; width: 20px; height: 20px;'></div>"?></td>
<td><a href='?id=change_css&div=h1' class='under'>Change</a>
</td>
</tr>
<tr>
<td>
H2
</td>
<td align='center'>
<?php echo "<div id='div_h2' class='css' style='background-color: #$h2; width: 20px; height: 20px;'></div>"?></td>
<td><a href='?id=change_css&div=h2' class='under'>Change</a>
</td>
</tr>
</table>
</td>
<td valign='top'>
CSS Styler Preview:<br/><br/>
<?php
echo "<table summary='preview' border='0'>\n<tr>\n<td width='350px' style='background-color:#$background; border:2px black solid;'>\n";
echo "<span style='color:#$text;'>Normal Body Text</span>\n";
echo "<br/><br/>\n";
echo "<span style='color:#$link; cursor:pointer;' class='under'>Regular Links</span>\n";
echo "<br/><span style='color:#$activelink; cursor:pointer; border-bottom:1px #$activelink solid'>Active Links (MouseOver)</span>\n";
echo "<br/><span style='color:#$vlink; cursor:pointer; border-bottom:1px #$vlink solid'>Visited Links (Already Visited)</span>\n";
echo "<h1 style='color:#$h1'>H1 Header</h1>\n";
echo "<h2 style='color:#$h2'>H2 Header</h2>\n";
echo "</td>\n</tr>\n</table>";
?>
</td>
</tr>
</table>
<br/>
<input type='submit' style='font-weight:bold' value='Save Changes'/>
<input type='button' onclick="location.href='?id=css_reset'" name='cancel_css' id='cancel_css' value='Cancel Changes'/>
</form>