I am trying to put a div into append but I am always getting SyntaxError: missing ) after argument list
My div look like
<div class='col-md-6'>
<div class='form-group'>
<?= $this->Form->control('user_id', ['options' => $users,'class'=>'form-control']);?>
</div>
<div class='form-group'>
<?= $this->Form->control('phone_number',['class'=>'form-control']); ?>
</div>
</div>
I have tried in append like below
$('#cform').append("<div class='col-md-6'><div class='form-group'><?= $this->Form->control('user_id', ['options' => $users,'class'=>'form-control']);?></div><div class='form-group'><?= $this->Form->control('phone_number',['class'=>'form-control']); ?></div></div>");
I am not getting any syntax error here, How can I solve this ?