Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7072061
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 28, 20262026-05-28T05:45:46+00:00 2026-05-28T05:45:46+00:00

I have 3 tables on a page. Each of them contain two table rows.

  • 0

I have 3 tables on a page. Each of them contain two table rows.

The first <tr> holds a RadioButton. The second <tr> is set to display: none. I need to second <tr> to display when the RadioButton in that particular table was selected.

My HTML:

<table class="tableClass" style="width: 98%">   
    <tr>
       <td>
           <input type="radio" id="rbResource" onclick="radio_Click()" class="radioButton"       runat="server" />
       </td>  
    </tr>
    <tr class="displaySelection" style="display: none">
       <td>
           <span>Test</span>
       </td>
    </tr>
</table>

I’m not sure how to form my jQuery int the radio_Click() function to get what I’m looking for. Everything I’ve tried so far, displays all three <tr> of each table regardless of which Radiobutton was selected.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-28T05:45:47+00:00Added an answer on May 28, 2026 at 5:45 am

    If I understand correctly, you need only 1 row to be visible each time, depending on the radiobutton pressed. To begin with, you should use name=”rbResource” (rather than id) to group the radiobuttons together. Then you can use something like this:

    $(".radioButton").click( function(evt) {
        $(".radioButton").each( function( index, obj ) {
            var checked = $(obj).attr('checked')==true;
            var row = $(obj).closest('tr').next();
            if ( checked ) row.show();
            else row.hide();
        });
    });
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

On a single page, I have two tables. Each of them has a class
I have a page that displays a table in two different modes. In each
I want to place a table on my page. I have two tables in
I have two tables. I want them be near each other and not like
I have a page with lots of tables, each with a link inside. I
I have a table of pages in my database, each page can have a
I have several pages to do with several table on each page. I've got
I have a site with multiple pages, and each page has a table that
I have two tables, one contains the page/heading number and the heading text, the
I have two related tables in my database: Page and Tag. One Page can

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.