The SitePoint Forums have moved.

You can now find them here.
This forum is now closed to new posts, but you can browse existing content.
You can find out more information about the move and how to open a new account (if necessary) here.
If you get stuck you can get support by emailing forums@sitepoint.com

If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

Looking for a highlight and checkbox script

I have some, but they are very long and complicated for my brain and not quite what I need.
I am looking for a script, like in a mailbox, that when you check, the row of a table changes the colour (but it has to be on a input level, I can't have tags with ID or things like that on the TR/TD). And on top of that, this script should also check/uncheck all (those little boxes on the Thead of the table that when you tick, tick all checkboxes or uncheck them!

<body>
<br>
I have some, but they are very long and complicated for my brain and not quite what I need.<br>
<br>
I am looking for a script, like in a mailbox, that when you check,<br>
the row of a table changes the colour (but it has to be on a input level,<br>
I can't have tags with ID or things like that on the TR/TD).<br>
<br> And on top of that,
<br> this script should also check/uncheck all<br>
(those little boxes on the Thead of the table that when you tick, tick all checkboxes or uncheck them!
<br>
<input type="checkbox" name="" checked="checked"><br>
<input type="checkbox" name="" checked="checked"><br>
<input type="checkbox" name="" checked="checked"><br>
<input type="checkbox" name="" checked="checked"><br>
<input type="checkbox" name="" checked="checked"><br>
<input type="button" name="" value="CheckBox = true" onclick="CheckBox(true);" ><br>
<input type="button" name="" value="CheckBox = false" onclick="CheckBox(false);"><br>
</body>

Thanks for replying, but what I had in mind was something a bit different. I have a table and the first column is just checkboxes, what I wanted was the top checkbox, when clicked, would get all checkboxes checked and unchecked. And at the same time, when you tick a checkbox, the background of that row chances, to call the persons attention that that row/rows were checked. I'm sure I could merge those two scripts your wrote to me somehow, but I really have no idea how....

<body>
And at the same time, when you tick a checkbox,<br>
the background of that row chances, to call the persons attention that that row/rows were checked.<br>
I'm sure I could merge those two scripts your wrote to me somehow, but I really have no idea how....