...

View Full Version : problem with selecting table row.



BabySpidy
09-20-2005, 12:18 PM
Hello there guys.

I have attached here my html file along with javascript.
As you can check from my html file, when I select a table row, the selected row property(background color, border) changed. However, when I select another table row, the previous selected row didn't back to the original property of it. With my given javascript, I'm having a hard time to figure it out how it will back to the original property.
Can please someone out there try to check my script and help me with this matter.

Thanks.

Vladdy
09-20-2005, 02:20 PM
Attaching zipped files to your post is about the worst way to get help - you would have to wait for a rather altruistic soul with patience to save, unzip, load to come along... ;) Best is to provide a link to the code in question, or post relevant parts of it.
That said, you are welcome to examine the following sample and extract the functionality you are after: http://webdeveloper.klproductions.com/demos/movetr.html

BabySpidy
09-20-2005, 06:47 PM
Thanks for the link, though it didn't help me with my problem. :confused:
As on my attached file, I think, it's only a matter of manipulation with the script to work things fine. Hope someone out there may check my scripts so that I will know what went wrong with my scripts.

One more thing, I attached my files so that someone may know what my problem is, coz I think that if I only post the script code, you may wonder what problem I am pointing to.

Thanks again.

webgeo99
09-22-2005, 08:01 PM
Vladdy,
I wanted to extract the code for that page and could not view the source.
Could you send it to me or tell me how to get it? Thanks. :thumbsup:

KC-Luck
09-22-2005, 09:34 PM
change the following lines:



// line 31
trs[j]._className = trs[j].className + addClass;

// line 36: within set_color()
this.className = this._className + classType;

it continued to increment the className each click.

Vladdy
09-23-2005, 04:14 AM
Vladdy,
I wanted to extract the code for that page and could not view the source.
Could you send it to me or tell me how to get it? Thanks. :thumbsup:
There is nothing on that page that attempts to prevent you from viewing the source. Check your browser setting..... I remember there was a cache related problem with IE not doing "View Source".... You can always "save the page as" too - all my demos are single page documents: all JS, CSS and HTML are there - no linked resources to make it easier for people to see how its done



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum