Skip to content

Instantly share code, notes, and snippets.

@mnithya

mnithya/fill.ctp Secret

Last active December 12, 2015 16:05
Show Gist options
  • Save mnithya/fa2fadad3ae21927ee87 to your computer and use it in GitHub Desktop.
Save mnithya/fa2fadad3ae21927ee87 to your computer and use it in GitHub Desktop.
<div class="container">
<div class="form-group">
<?= $this->Form->create($assessmentForm) ?>
<fieldset>
<legend><?= __($assessmentForm->title) ?></legend>
<?php foreach ($questions as $question): ?>
<?php echo $this->Form->hidden('qid', ['value'=>$question->qid]) ?>
<?php echo $this->Form->input($question->qid.'.answer_text', ['label' => $question['text']]) ?>
<?php endforeach; ?>
</fieldset>
<?= $this->Form->button(__('Submit')); ?>
<?= $this->Form->end() ?>
</div>
</div>
~
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment