adamwathan / bootforms

Rapid form generation with Bootstrap 3 and Laravel.
MIT License
417 stars 103 forks source link

form-group #119

Closed hugofabricio closed 7 years ago

hugofabricio commented 7 years ago

How to remove form-group class or group div of input?

adamwathan commented 7 years ago

Can't; this library is designed to make it easy to generate standard Bootstrap form markup. If you need different markup, better to write it by hand or use another library.

Bootforms uses this library under the hood that might be useful:

https://github.com/adamwathan/form

jesseleite commented 7 years ago

@hugofabricio If you chain removeClass() after an group() like this...

BootForm::text('Wat', 'wat')
    ->group()
    ->removeClass('form-group')

It will output...

<div>
    <label class="control-label" for="wat">Wat</label>
    <input type="text" name="wat" id="wat" class="form-control">
</div>

Notice the class is removed from parent div. But as Adam said, there's no way to remove the div itself with Bootforms 👍

hugofabricio commented 7 years ago

Thanks man! :D