Solved

How to increase or decrease the height of an input textbox

Posted on 2007-04-07
3
465 Views
Last Modified: 2010-08-05
Excuse me for a dumb question but is there any way to reduce the height of an input text box?

For instance, I would like to have the abiliy to increase or decrease the following line:

<TD><INPUT TYPE="TEXT" SIZE="5" NAME="OpenBal" VALUE=""></TD>

I can increase or decrease the default height

Any ideas?

Thanks in advance
0
Comment
Question by:simflex
3 Comments
 
LVL 4

Expert Comment

by:Cyber-Drugs
ID: 18870525
Hi simflex,

You are after some CSS to achieve what you are after.


Try this:

http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/CSS/Q_21630573.html
0
 
LVL 10

Accepted Solution

by:
js_vaughan earned 50 total points
ID: 18870542
You will need to use CSS.  You can also control the font-size as well using the em standard, or by pixels (px).  If you dont need to alter the font-size just remove that part from the code below.  Depending on your needs, here are 3 ways to impliment it:

This will change the size of ALL your input tags:
<style type="text/css">
<!--
    input{height:24px; font-size:1.2em;}
-->
</style>

Lets say you only want to do one box, and not all of them, replace the style with this:
<style type="text/css">
<!--
    input.largebox{height:24px; font-size:1.2em;}-->
</style>

And then add ...  class="largebox" ... to your input tage.

Those are the best two ways.  If you want "quick and dirty" then you can apply the stlye to the tag itself, like so:
<TD><INPUT TYPE="TEXT" SIZE="5" NAME="OpenBal" VALUE="" STYLE="height:24px; font-size:1.2em;"></TD>
0
 

Author Comment

by:simflex
ID: 18871018
thanks very much
0

Featured Post

How to run any project with ease

Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
- Combine task lists, docs, spreadsheets, and chat in one
- View and edit from mobile/offline
- Cut down on emails

Join & Write a Comment

This article discusses how to create an extensible mechanism for linked drop downs.
This article explains how to prepare an HTML email signature template file containing dynamic placeholders for users' Azure AD data. Furthermore, it explains how to use this file to remotely set up a department-wide email signature policy in Office …
The viewer will learn how to count occurrences of each item in an array.
The viewer will learn how to create and use a small PHP class to apply a watermark to an image. This video shows the viewer the setup for the PHP watermark as well as important coding language. Continue to Part 2 to learn the core code used in creat…

746 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

11 Experts available now in Live!

Get 1:1 Help Now