...

View Full Version : Problem with <table>



GeorgeSG
03-14-2005, 11:05 AM
Hi guys!
First - excuse me for my bad english!
Here is my problem:
In my site I want to use a holl line in the table for hyperlink, but I made my site with frames, so I can't set(?) the line-hyperlink to open the document in another frame. Here is the code I used:


<tr bgcolor="#981B1E" onmouseover="Over(this)" onmouseout="Out(this)" height="30">
<td onclick="self?.location='Link.html'"><font style="FONT-SIZE: 12px;COLOR: #FFFFFF;FONT-FAMILY: Verdana, serif;TEXT-DECORATION: none;">&nbsp;&nbsp;&nbsp;Text</font></td>
</tr>

Hope you'll understand me! Thanks in advance!

ronaldb66
03-14-2005, 01:14 PM
Why do you use Javascript for that and not an a element? You could simply use the target attribute to load the linked page in any named frame you wish.

_Aerospace_Eng_
03-14-2005, 02:57 PM
or making a link in that td cell and set the css to display block

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<title>Untitled Document</title>
<style type="text/css">
td.blockcell {
height:50px;
width:100px;
}
a.blocked,a.blocked:link,a.blocked:visited,a.blocked:hover,a.blocked:active {
text-decoration:none;
color:#FFFFFF;
background:#000000;
display:block;
width:100%;
height:100%;
}
a.unblocked,a.unblocked:link,a.unblocked:visited,a.unblocked:hover,a.unblocked:active {
text-decoration:none;
color:#FFFFFF;
background:#000000;
}
</style>
</head>
<body>
<table id="table1">
<tr>
<td class="blockcell"><a class="blocked" href="blah.com" target="blah">Text</a></td>
</tr>
<tr>
<td class="blockcell"><a class="unblocked" href="anotherblah.com" target="blah">More Text</a></td>
</tr>
</table>
</body>
</html>



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum