[Last Call] Learn how to a build a cloud-first strategyRegister Now

  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 514
  • Last Modified:

Making small text boxes

I'm new to web development in general so I may be missing something simple.  I'm trying to create small text boxes, but if I do

<INPUT type="text" NAME="textbox" MAXLENGTH=5 SIZE=1>

it's about twice as long as I need it to be.  Is there a way to make it smaller by maybe setting the size by pixels or a percentage of the screen?
1 Solution
You need to add a bit of css to that. You need to define width, height and font-size:
Play around with the code below:
<INPUT type="text" NAME="textbox" MAXLENGTH=5 SIZE=1 style="width:30px;height:12px;font-size:10px;">

Open in new window

iwtblj247Author Commented:
Worked great.  Thanks

Featured Post

Concerto's Cloud Advisory Services

Want to avoid the missteps to gaining all the benefits of the cloud? Learn more about the different assessment options from our Cloud Advisory team.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now