Jump to content


Two cell highlight questions...


5 replies to this topic

#1 c.designs

    Young Padawan

  • Members
  • Pip
  • 128 posts

Posted 02 October 2005 - 12:33 PM

The code I used to get that nifty cell highlight is:

td.cell:hover
{
background-color:#6C9FCE;
display: block { width: 200 px; height:15 px;
}

I know this isn't 100 % right... But it does work in Firefox. How can I get this to work in IE aswell?

And how do I link the entire cell, not just the text?

#2 softLearner

    Young Padawan

  • Members
  • Pip
  • 128 posts

Posted 02 October 2005 - 01:22 PM

The :hover persuado class is only supported on links onlym although this should be fixed for IE7!

The only way to get around this by Javascript, using the onmouseover and onmouseout attributes to call a javascript function that will change the colors of thh table cell.

#3 Stu

    Retired P2L Staff

  • Publishing Betazoids
  • PipPipPipPip
  • 1,761 posts
  • Gender:Male

Posted 02 October 2005 - 01:29 PM

c.designs, on Oct 2 2005, 05:33 PM, said:

The code I used to get that nifty cell highlight is:

td.cell:hover
{
background-color:#6C9FCE;
display: block { width: 200 px; height:15 px;
}

I know this isn't 100 % right... But it does work in Firefox. How can I get this to work in IE aswell?

And how do I link the entire cell, not just the text?
why do you have 2 {'s in there?

#4 c.designs

    Young Padawan

  • Members
  • Pip
  • 128 posts

Posted 02 October 2005 - 01:33 PM

I change it to this:
td.cell:hover { 
	text-decoration:none; 
	color:#fff; 
	background-color:#6c9fce; 
	display:block-width: 199px; block-height: 15px;
}
And it still doesn't work.

But that's not really a problem. How do I make the entire cell a link? Would it be something like <td class="a"> or something? But I already have the class set as 'cell'.

EDIT: I'm not going to use Javascript just on the cole reason that I like CSS better :)

I already used JS on the nav buttons.

Edited by c.designs, 02 October 2005 - 01:34 PM.


#5 coolaid

    P2L Jedi Master

  • Members
  • PipPipPipPip
  • 1,435 posts
  • Gender:Male
  • Interests:i wonder..

Posted 02 October 2005 - 02:15 PM

yea dude, use javascript, its obvious you copy pasted and snipped that code cause you got so many obvious errors where things are left out.

but to awnser,

to make the entire td a link, you would do somethin like <td><a href="">link</a></td>

and use some css

td a{
width:300px;
}

html>body td a{
width:auto;
}

but yea, use javascript..

#6 c.designs

    Young Padawan

  • Members
  • Pip
  • 128 posts

Posted 02 October 2005 - 07:54 PM

Thanks for the help. I used the javascript and now it works fin in both IE and FF. But I can't seem to get the entire td linked.





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users