9
I have a textarea
with a placeholder
which according to the documentation (English) is perfectly valid and should work:
Part of the form
<?php
/* Apenas o código referente à textarea
*/
$oc_message = isset($postArr["oc_message"]) ? cleanStr($postArr["oc_message"]) : '';
$form = '
<div class="form-group">
<label for="oc_message">
'.ucfirst(I18N_WORD_MESSAGE).' <small class="text-danger">*</small>
</label>
<textarea class="form-control" id="oc_message" name="oc_message" placeholder="'.I18N_PLACEHOLDER_MESSAGE.'" rows="10">
'.$oc_message.'
</textarea>
</div>';
?>
However, the text of placeholder
does not appear in the same!
HTML generated:
<div class="form-group">
<label for="oc_message">
Mensagem
<small class="text-danger">*</small>
</label>
<textarea rows="10" placeholder="Introduza a sua mensagem" name="oc_message" id="oc_message" class="form-control">
</textarea>
</div>
Question
Why is the placeholder
is not appearing?
As both answers speak of the same, it is accepted for having been put first.
– Zuul