Hi ,
i am having a ajax post like
var ht = $.ajax({
type: "GET",
url: "http://localhost/FormBuilder/index.php/forms/viewChoices/"+attribute_id,
async: false
}).responseText;
var myObject = eval('(' + ht + ')');
var data = myObject;var j=0;
alert(data.choices);//alerts the choices as object
$(""+<?php echo $form->input('field', array('type' => 'radio','legend'=>$r['Attribute']['label'],'separator' => '--separator--',
'options' => array() ));?>+"").appendTo("#"+<?=$r['Attribute']['id'];?>);
In the last line where i am creating a Radio button inside JQUery which shows me the legend correclty but i am trying to use the data.choices which is a JQuery variable inside PHP array i.e. in 'options'=> array() How to do so ???