Here is the code I am having:
<div id="removequestions"></div>
var html += '<input type=radio name=questions />';
$.('#removequestions').append(html);
The javascript error I am getting on executng the above code is:
XML filter is applied to non-XML value (function (a, b) {return new c.fn.init(a, b);})
Any idea why this error occurs. I want to add radio button dynamically.
Represent this way:-
var html = "";
html += '<input type=radio name=questions />';
$('#removequestions').append(html);
Another Best way of Representation:-
var ques = $('#removequestions');
$('<input>').attr({
'type': 'radio',
'name': 'questions'
}).appendTo(ques);
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.