473,480 Members | 5,041 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

highlight a row

I have a table of many rows which is made of many cloumns.

Using CSS I would like to highlight an entire given row when the mouse is
over it.

I know a:hover will do this, but not every column of the row will be a link.

Is what I am seeking possible, and if so, could someone point me in the
right direction?

Thank you for you help
Jul 20 '05 #1
1 11976
snet wrote on 15 jul 2003 in comp.infosystems.www.authoring.stylesheets:
I have a table of many rows which is made of many cloumns.
Using CSS I would like to highlight an entire given row when the mouse
is over it.
I know a:hover will do this, but not every column of the row will be a
link.
Is what I am seeking possible, and if so, could someone point me in
the right direction?


Use javascript + css:

========== test.html =========

<style>
tr.tr td {background-color:white;}
tr.trred td {background-color:yellow;}
</style>

<script>
function h(x){
x.className="trred"
}
function n(x){
x.className="tr"
}
</script>

<table border=1>

<tr class="tr"
onmouseover="h(this)"
onmouseout="n(this)">
<td>qwerty</td><td>qwerty</td></tr>

<tr class="tr"
onmouseover="h(this)"
onmouseout="n(this)">
<td>qwerty</td><td>qwerty</td></tr>

<tr class="tr"
onmouseover="h(this)"
onmouseout="n(this)">
<td>qwerty</td><td>qwerty</td></tr>

</table>

=========================

--
Evertjan.
The Netherlands.
(Please change the x'es to dots in my emailaddress)
Jul 20 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1739
by: Doug Farrell | last post by:
Hi all, I'm trying to use the PHP GD functions to make graphical changes to image files. In particular I'm trying to add a 'highlight' rectangle to an image. So far everything I've tried doesn't...
13
4508
by: David Morgan | last post by:
Hello I have a little function to highlight text if it exists. Function Highlight(vFind, vSearch) Dim RegEx Set RegEx = New RegExp RegEx.Pattern = vFind RegEx.IgnoreCase = True Highlight =...
9
3027
by: Devron Blatchford | last post by:
Hi there, Just wondering if I change the back and fore colour of a listview item when the mouse hovers over it? I want to overide the default windows colour. Can someone please tell me how to...
5
10865
by: Atara | last post by:
I am trying to convert the following code to VB .Net, I still have some gaps (the lines that are marked with (*)) and also I need an ending condition for the while loop. any help would be...
2
1766
by: Number 11950 - GPEMC! Replace number with 11950 | last post by:
When you highlight a selection of text represented in an object on a form, somewhere in the Framework or alternatively in the Windows API there exists an array of variables that either contain as a...
2
2905
by: Celeste | last post by:
Hello, I'm trying to parse the referring url for google search terms so that when this page loads it will scroll to and highlight the search term(s). Should i be using document.referrer? ...
0
6818
Merlin1857
by: Merlin1857 | last post by:
A thing I have been asked for on a number of occasions is the ability to highlight text after its been searched for in a record return page. The following does this perfectly. Use this function...
4
2786
by: Andrew Poulos | last post by:
As a user tabs about a web page I want to highlight with a, say, 2 pixel solid yellow border the anchor that currently has focus. When the anchor loses focus the border is removed. The anchors...
3
1820
sujathaeeshan
by: sujathaeeshan | last post by:
Hello all, I want to highlight or select data grid row based on first letter of first column in data grid with keyboard. Just by pressing the key of first letter of the column ,it has to...
0
7040
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
6905
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7041
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
1
6736
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5331
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
2994
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
2980
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
1299
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...
1
561
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.