cakephp-plugin-boost_cake
cakephp-plugin-boost_cake copied to clipboard
Alignment/positioning issues with file inputs...
The layout and spacing seems to be off for form inputs
This is the cake code:
<?php
echo $this->Form->create('NewsPost', array(
'type' => 'file',
'inputDefaults' => array(
'div' => 'form-group',
'label' => array(
'class' => 'col col-md-2 control-label'
),
'wrapInput' => 'col col-md-10',
'class' => 'form-control'
),
'class' => 'well form-horizontal'
));
?>
<?php
echo $this->Form->input('NewsImage.0.image', array(
'type' => 'file'
));
?>
And the resulting markup:
<div class="form-group">
<label for="NewsImage0Image" class="col col-md-2 control-label">Image</label>
<div class="col col-md-10">
<input type="file" name="data[NewsImage][0][image]" class="form-control" id="NewsImage0Image"/>
</div>
</div>
Do you expect what output HTML? I think it's a matter of CSS.
(by Chrome)
I was using firefox - so is it a problem with firefox button rendering?
Yes i think, I try and use firefox and the rendering output same with you ? I suggest to use jasny bootstrap file upload component, working well in firefox and chrome but is based bootstrap 2 http://jasny.github.io/bootstrap/javascript.html#fileupload
To slywalker , can create helper for jasny file upload component, Hheee *ups sorry :D
I'm using what these. Demo for Bootstrap File Input styler