<html>
<head>
<title>Tabs</title>
<style>
.link{
font-family:tahoma;
font-size:11px;
font-weight:bold;
color:white;
text-decoration:none;
}
</style>
</head>
<body>
<?php
$id=1;
$links=array("Home","Link1","Link2","Link3","Link4");
$total_links=count($links);
?>
<table cellpadding="0px" cellspacing="0">
<tr>
<td> </td>
<?php
for($i=0;$i<$total_links;$i++){
if($i+1==$id){
?>
<td style="padding-left:1px">
<table cellpadding="0" cellspacing="0">
<tr>
<td><img src="images/selectedLeft.gif" /></td>
<td style="background-image:url(images/selectedCenter.gif);" class="link"><?php echo $links[$i] ?></td>
<td><img src="images/selectedRight.gif" /></td>
</tr>
</table>
</td>
<?php } else { ?>
<td style="padding-left:1px">
<table cellpadding="0" cellspacing="0">
<tr>
<td><img src="images/normalLeft.gif" /></td>
<td style="background-image:url(images/normalCenter.gif);"><a href="?id=<?php echo $i+1; ?>" class="link"><?php echo $links[$i]; ?></a></td>
<td><img src="images/normalRight.gif" /></td>
</tr>
</table>
</td>
<?php } // else end
} //for end
?>
<td> </td>
</tr>
<tr>
<td colspan="<?php echo $total_links+2?>" bgcolor="#6363ff"> </td>
</tr>
<tr>
<td colspan="<?php echo $total_links+2?>" style="border:1px #1895D5 solid;">
<h1 style="color:#000000">link #<?php echo $id?> goes here ...</h1>
</td>
</tr>
</table>
</body>
</html>
What did I miss?

New Topic/Question
Reply



MultiQuote






|