Skip to main content

Search and Top Navigation

#7505 closed bug (fixed)

Opened June 25, 2011 09:40AM UTC

Closed November 19, 2012 01:39PM UTC

Last modified November 19, 2012 01:46PM UTC

Button: Buttonset not applied to radio group with quotation/apostrophe in name

Reported by: meotimdihia Owned by: dalekocian
Priority: minor Milestone: 1.10.0
Component: ui.button Version: 1.9.0
Keywords: Cc:
Blocked by: Blocking:
Description

BUTTON SET is bug with this code:

<form>
	<div id="radio">
		<input type="radio" id="radio1" name="data['Page']['parse']" /><label for="radio1">Choice 1</label>
		<input type="radio" id="radio2" name="data['Page']['parse']" checked="checked" /><label for="radio2">Choice 2</label>
		<input type="radio" id="radio3" name="data['Page']['parse']" /><label for="radio3">Choice 3</label>
	</div>
</form>

</div><!-- End demo -->
<script>
	$(function() {
		$( "#radio" ).buttonset();
	});
</script>
Attachments (0)
Change History (11)

Changed June 27, 2011 02:17PM UTC by scottgonzalez comment:1

component: ui.coreui.button

Changed July 22, 2011 02:29PM UTC by epascarello comment:2

Problem here is it grabs the name

var name = radio.name,

and than builds a selector:

radios = $( form ).find( "[name='" + name + "']" );

Looks like : ' [ ] would need to be escaped

Changed October 11, 2012 02:43PM UTC by scottgonzalez comment:4

milestone: 1.9.01.11.0

Changed October 15, 2012 08:39PM UTC by bchiasson comment:5

status: newopen
summary: Buttonset Bug when radio with name = "data['page']['parse']"Button: Buttonset not applied to radio group with quotation/apostrophe in name
version: 1.8.131.9.0

The issue arises when the string delimiter "'" is placed into the name attribute. The link below is the tickets code.

http://jsfiddle.net/bchiasson/Gn6Kz/2/

Changed October 15, 2012 09:28PM UTC by dalekocian comment:6

owner: → dalekocian
status: openassigned

Changed October 15, 2012 09:28PM UTC by dalekocian comment:7

resolution: → fixed
status: assignedclosed

Changed October 15, 2012 09:36PM UTC by scottgonzalez comment:8

resolution: fixed
status: closedreopened

Changed October 27, 2012 08:19PM UTC by mikesherov comment:9

status: reopenedopen

Changed November 19, 2012 01:39PM UTC by Mike Sherov comment:10

resolution: → fixed
status: openclosed

Button: properly escape button names. Fixes #7505 - Button: Buttonset not applied to radio group with quotation/apostrophe in name.

Changeset: cc7df712cc4ca90f6d6db599c5ff91b690921581

Changed November 19, 2012 01:46PM UTC by mikesherov comment:11

milestone: 1.11.01.10.0