-1

I have a table where I want to fix the height to larger than the default value (for aesthetic reasons), the problem is : the links are only active for the text area and not the entire height. I already have it as display: block ...any help?

            .myTable {border-collapse: collapse; text-align:center;float:none; 
        border: 10px #ccc solid;
          }
            .myTable td { width:150px ;height:80px;background:#55ddff; }
            .myTable td a {display: block; }

and this is the html body:

<table class="myTable">
<TR><TD><a href="">hello</a></TD></TR>
<TR><TD><a href="">hello</a></TD></TR>
<TR><TD><a href="">hello</a></TD></TR>
</table>
Brian Tompsett - 汤莱恩
  • 5,753
  • 72
  • 57
  • 129
Hussam Sibai
  • 97
  • 2
  • 9
  • Possible duplicates of http://stackoverflow.com/questions/3337914/how-to-make-a-td-a-link and http://stackoverflow.com/questions/10070232/how-to-make-a-cell-of-table-hyperlink – hop Apr 20 '13 at 20:17
  • i dont see what i did wrong to lose reputation !! that question may be close to mine but the answers were not clear to me ... – Hussam Sibai Apr 20 '13 at 20:22
  • this is outrageous !!! you get punished for asking a question ...wow – Hussam Sibai Apr 20 '13 at 20:27
  • Width 100% and Height 100% are the one missing there and that is what is stated in the answers there. I am not sure, what was not clear to you. – hop Apr 20 '13 at 20:34
  • And even if it wasn't clear, you could have asked your doubts as comments there and I am sure the community would have helped you. – hop Apr 20 '13 at 20:35
  • If you need your reputation back and "if you genuinely think its a duplicate question", you can delete this question. – hop Apr 20 '13 at 20:36

1 Answers1

1

Try this:

.myTable td a {display:block;width:100%;height:100%;margin:0}
lucuma
  • 18,247
  • 4
  • 66
  • 91