In the HTML form, I have a file field similar to this:
<div class="filefield"> <input type="file" name="myfile" id="fileinput"> </div>
It displays a button and some text other than a button. If the file has not yet been selected, the text: No file chosen . If a file is already selected, it displays the file name.
This text is displayed on the right side of the button. I want it to appear under the button. I tried a lot of things in CSS and nothing works, No file chosen always displayed on the right side of the button, even if both the div and the input are given fixed widths only widths like a button, and fixed heights high enough for a button and two lines of text , the text is still displayed on the right, outside the div, and not below where the space inside the div is. How to make the text appear under the button?
miernik
source share