By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,676 Members | 1,636 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,676 IT Pros & Developers. It's quick & easy.

How to chang bgcolor of row when mouse selected a row?

P: n/a
How to chang bgcolor of row when mouse selected a row?

I have a HTML table in the page. I hope to change <tr.bgcolor> when user
clicks on a column, just like user has selected this row.

How can I do that ?

Thanks

Charles Shao:-)
Nov 19 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
You should setup client-side onclick event for evry <tr>. In the event
handler you can change bgcolor for the new-clicked row and restore normal
color for the previously clicked row. Store the reference to the
previously-clicked row in a javascript variable.

Eliyahu

"Charles Shao" <ad****@263.net> wrote in message
news:OK**************@TK2MSFTNGP15.phx.gbl...
How to chang bgcolor of row when mouse selected a row?

I have a HTML table in the page. I hope to change <tr.bgcolor> when user
clicks on a column, just like user has selected this row.

How can I do that ?

Thanks

Charles Shao:-)

Nov 19 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.