html - Can number of dashes be determined in css border bottom property? -
I have an input text box with the following requirements.
- with fixed size
- Input text: & lt; Input size = "5" maxlength = "5" /> & Lt; / Div & gt;
I'm trying to say that is Bella.
Is the number of dashes equal to the value of text box size possible?
If yes, how can I do this?
Firstly it is not possible . Each browser separates different borders.
You can use a workaround. In the following example I have added a ul
which simulates the number of characters that can be used
input {border: none; Border: 0 px dashed; Letter-spacing: 2px; } Input: Focus {framework: 0} div {boundary: 2px solid #CCC; Padding: 50px; } UL {status: relative; Top: -35px; Correct: -30px; Height: 1px; } Li {Display: Inline; Margin: 0 2px; List-style-type: none; Font-size: 8px; }
& lt; Div & gt; Input text: & lt; Input size = "5" maxlength = "5" /> & Lt; Ul & gt; & Lt; Li & gt; _ & Lt; / Li & gt; & Lt; Li & gt; _ & Lt; / Li & gt; & Lt; Li & gt; _ & Lt; / Li & gt; & Lt; Li & gt; _ & Lt; / Li & gt; & Lt; Li & gt; _ & Lt; / Li & gt; & Lt; / Ul & gt; & Lt; / Div & gt;
Comments
Post a Comment