I am trying to insert a Font Awesome icon in a submit button using CakePHP and Twitter Bootstrap 3.
Here is the code:
echo $this->Form->submit('Send', array('class' => 'btn btn-warning fa fa-envelope', 'escape' => false));
It works for regular buttons, but for the input that which is generated by the FormHelper above, it does not render with an icon. Can I tweak FormHelper::submit to solve this?
I could use other types of FormHelper buttons, but the CakePHP docs explicitly states that:
Try to avoid using FormHelper::input() to generate submit buttons. Use FormHelper::submit() instead.