Skip to content
View in the app

A better way to browse. Learn more.

Web Designer Forum

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

styling a tr a:hover

Featured Replies

How would I style the hover on this table here:

 

http://universitycompare.net/university-guide

 

I want the hover to be light a like blue so you know you are hovering over that line, and also make that whole line a hyperlink, but kind of don't know where to start?

 

I have tried a few things but It doesn't seem to be working :/

Does this help? Also take a look at this for making the whole tr a hyperlink.

Edited by Bomb

If use use a HTML5 doctype then you can sematically make a whole table row a link:

 

<a href="#">
<tr>
<td>Cell</td>
<td>Cell</td>
<td>Cell</td>
</tr>
</a>

  • Author

If use use a HTML5 doctype then you can sematically make a whole table row a link:

 

<a href="#">
<tr>
<td>Cell</td>
<td>Cell</td>
<td>Cell</td>
</tr>
</a>

 

I am using a HTML5 Doctype and I've done that, However, when I apply a class or hover, it doesn't work? What am I missing?

 

I guess I just style that class? right? Bit confused what to put in the css?

<a href="#" class="hover">
<tr>
<td>Cell</td>
<td>Cell</td>
<td>Cell</td>
</tr>
</a>

 

CSS

a.hover:hover {color: red;}

 

???

  • Author

tr:hover {
background:#000;
}

 

Will only work on recent browsers (not IE) or you can use jQuery like this

 

I tried this and it didnt work?

 

<a href="#" class="hover">
<tr>
<td>Cell</td>
<td>Cell</td>
<td>Cell</td>
</tr>
</a>

 

CSS

a.hover:hover {color: red;}

 

???

 

 

I also tried this and it didn't work? I thought I was doing something wrong as I had tried both of these before asking again? I had a look online for jquery answers, but it must be able to be done through HTML 5!

Create an account or sign in to comment

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.