Loading...
Copy code
Close
Permalink
Close
Please tell us why you want to mark the subject as inappropriate.
(Maximum 200 characters)
Report Inappropriate
Cancel
Private Message
From :
guest
To :
Subject :
Content :
Type the characters you see in the picture below.
Send
Cancel
From :
guest
To :
Subject :
Content :
Type the characters you see in the picture below.
Send
Update
Cancel
Feedback
Email ID
Subject :
Comments :
Send
Cancel
Private Message
Type the characters you see in the picture below.
Type the characters you see in the picture below.
Attach files
Desktop
Zoho Docs
Google Docs
Each Attachment size should not exceed 1MB.
Max no of attachments : 3
Loading User Profile...
guest
Response title
This is preview!
Attachments
Publish
Back to edit
Cancel
(
)
Sign In
New to this Portal? Click here to
Sign up
You can also use the below options to login
Login with Facebook
Login with Google
Login with Yahoo
jQuery
Plugins
UI
Meetups
Forum
Blog
About
Donate
All Forums
Recent Posts
Log In
Search
jQuery
Search
jQuery Forum
Screen name:
ryolatl
ryolatl's Profile
1
Posts
6
Responses
0
Followers
Activity Trend
Last 30 days
Last 30 days
Date Interval
From Date :
To Date :
Go
Loading Chart...
Posts
Responses
PM
Show:
All
Discussions
Questions
Ideas
Problems
Expanded view
List view
Private Message
radios as buttons in a grid
[12Replies]
09-Nov-2012 01:12 PM
Forum:
Using jQuery UI
I'm trying to use a radios in a grid but They should look like a Button, so I use the buttonset.
I'm able to see the radios as button.
here is are the problems.
1.- I cannot set one of them as Checked by default so the button look highligthed
2.- after ther first row in the grid, the second row is just not taking the properties on the radios, because I can press both at the same time.
3. does it have something to with <label for="(the id of the radio"> ????
here is a little code that I'm using
this part, is a row on the grid.
<td style="text-align: center" rowspan="2">
<div id="views">
<input type="radio" id="button1" name="test" class="ui-helper-hidden-accessible" value="1" checked="true" >
<label for="button1">@Resources.Explosion.New.Current_Interface</label>
<input type="radio" id="button2" name="test" class="ui-helper-hidden-accessible" value="0" >
<label for="button2">Truck</label>
</div>
</td>
and here is part of my jquery where I change the name and the id of the radios in each row...
$("#explosionResults tr").each(function () {
var $radio = $(this).find("tr:eq(1)").find('input[type=radio]');
if ($radio.length > 0) {
$radio[0].name = rowCountername;
$radio[1].name = rowCountername;
//$radio[1].name = rowCountername;
rowCountername += 1;
$radio[0].id = rowCounterid;
$radio[0].for = rowCounterid;
rowCounterid += 1;
$radio[1].id = rowCounterid;
$radio[1].for = rowCounterid;
rowCounterid += 1;
}
});
also remeber that I'm using to format the radios as buttons
$('#views').buttonset();
I appreciate any help on this.
«Prev
Next »
Moderate user : ryolatl
Forum