Go Back   CodingForums.com > :: Client side development > JavaScript programming > JavaScript frameworks

Before you post, read our: Rules & Posting Guidelines

Reply
 
Thread Tools Rate Thread
Enjoy an ad free experience by logging in. Not a member yet? Register.
Old 09-19-2012, 08:02 PM   PM User | #1
asifakhtar
New Coder

 
Join Date: Feb 2009
Posts: 78
Thanks: 5
Thanked 0 Times in 0 Posts
asifakhtar is an unknown quantity at this point
How can I change class of all inputs by rowid(FormsRow) using Jquery?

How can I remove all inputs class from "Button" and assign "BigButton" class to all inputs by rowid(FormsRow) using Jquery. My table has 20 rows but I only want to change the following row's inputs tag's class:

Code:
<tr name="" id="FormsRow">
<td name="" id="" colspan="2"><input type="button" value="1st Letter" class="Button"></td>
<td name="" id="" colspan="2"><input type="button" value="2nd Letter" class="Button"></td>
</tr>
Thanks
asifakhtar is offline   Reply With Quote
Old 09-19-2012, 08:29 PM   PM User | #2
devnull69
Senior Coder

 
Join Date: Dec 2010
Posts: 2,261
Thanks: 10
Thanked 533 Times in 527 Posts
devnull69 will become famous soon enough
Code:
$('#FormsRow input').removeClass('Button').addClass('BigButton');
devnull69 is offline   Reply With Quote
Users who have thanked devnull69 for this post:
asifakhtar (09-19-2012)
Old 09-19-2012, 09:07 PM   PM User | #3
VIPStephan
The fat guy next door


 
VIPStephan's Avatar
 
Join Date: Jan 2006
Location: Halle (Saale), Germany
Posts: 7,703
Thanks: 5
Thanked 875 Times in 850 Posts
VIPStephan is a jewel in the roughVIPStephan is a jewel in the roughVIPStephan is a jewel in the rough
By the way: name is not a valid attribute for table rows and cells, and the ID attribute must not be empty.
__________________
Don’t click this link!
VIPStephan is offline   Reply With Quote
Old 09-19-2012, 09:18 PM   PM User | #4
asifakhtar
New Coder

 
Join Date: Feb 2009
Posts: 78
Thanks: 5
Thanked 0 Times in 0 Posts
asifakhtar is an unknown quantity at this point
Thanks. It works.
asifakhtar is offline   Reply With Quote
Reply

Bookmarks

Jump To Top of Thread


Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 01:40 AM.


Advertisement
Log in to turn off these ads.