Using HTML Placeholder in Laravel 4

前端 未结 5 1664
有刺的猬
有刺的猬 2020-12-31 01:38
{{ Form::text(\'username\', Input::old(\'username\')) }}

This is my code, I want to add Username as placeholder in the text box. I already use boot

5条回答
  •  暖寄归人
    2020-12-31 02:30

    Been a while since this was updated but with Former for Laravel the way to do this would be:

    Former::text('field')->placeholder('langfile.path.to.placeholder.text')))
    

    The lang file would be called langfile.php with the array containing:

     'Some Placeholder Text.'
        );
    

提交回复
热议问题