With materializeCSS I'm trying to place a button and a input field one near to the other (similar to default file input) as shown in the image below.
But I have an hard time achieving it because the input field label is above the button or the field is below the button.
<div class="row">
<div class="col s12 m4 l3">
<div class="file-field input-field">
<button class="waves-effect waves-light btn-large" type="submit" name="action">Button
</button>
<div class="file-path-wrapper">
<input id="email_input" type="text">
<label for="email_input">email</label>
</div>
</div>
</div>
</div>
http://codepen.io/anon/pen/rxKbZz
Is there a way to achieve it?
THANK YOU
In 2017 Align input text and button on its right code:
<div class="row">
<form class="col s12">
<div class="row">
<div class="input-field col s6">
<input id="name" type="text" class="validate">
<label for="name">Name</label>
</div>
<div class="input-field col s6">
<button class="btn waves-effect waves-light" type="submit" name="action">Go!
</button>
</div>
</div>
</form>
</div>
JSFiddle here
Hope it works!
just add the "input-field" class to your inputs and button containers
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With