1

It is possible to make the textfields on the left fill all the gray space to the right in a elastic way using CSS?

enter image description here

lushiano
  • 71
  • 5

2 Answers2

1

I did a jsFiddle example for you, demonstrating how you could do it. It's not the most approriate way because it's not dynamic. For example, the input fields must have a 50% width to fill in the space.
If you decide to have 4 input fields, you'd have to change from 50% to 25%.

But have a look at the example here: http://jsfiddle.net/peduarte/FwxhT/

Another way to do this, would be using javascript to calculate the gap and do a calculation to apply the remainder to the inputs, but again, not a great thing to do...

peduarte
  • 1,667
  • 3
  • 16
  • 24
0

Try <input type="text" style="width: 100%" />

Meisam Mulla
  • 1,845
  • 3
  • 23
  • 37