Solved

netscape, ie, and input boxes

Posted on 2003-10-21
4
272 Views
Last Modified: 2013-12-24
netscape seems to display vastly different sizes for input boxes than ie does in forms - is there anything to do about this (such as maybe through stylesheets) so that I don't have to do browser detection everytime i want to make a form

thanks,

justin
0
Comment
Question by:newstandard
  • 2
4 Comments
 
LVL 19

Accepted Solution

by:
cheekycj earned 150 total points
ID: 9591689
a few options:

STYLE="width:150px;" SIZE=150

or

http://www.faqts.com/knowledge_base/view.phtml/aid/14184/fid/337

CJ
0
 
LVL 17

Assisted Solution

by:anandkp
anandkp earned 50 total points
ID: 9592441
Use width attribute in style sheets for IE
& use "Size" attribute to netscape

eg : STYLE="width:100px;" SIZE=20

that shld be it -

PS : they both cannot be same ... as 150 wld be tooooooooo big for netscape

Hope that helps

K'Rgds
Anand
0
 
LVL 19

Assisted Solution

by:cheekycj
cheekycj earned 150 total points
ID: 9592486
I used 150 as an example.. Any size can be used there :-)

But in essense STYLE and SIZE combination is the solution I was getting at.

CJ
0
 
LVL 35

Assisted Solution

by:mrichmon
mrichmon earned 50 total points
ID: 9781855
I would recommend NOT using the SIZE attribute in them, instead use CSS and a stylesheet to define the width of the element in pixels or do it in the style of the element.

In general I prefer to have a class that defines the width.

You can either define a named class and then apply it using the class attribute like this :

(in the stylesheet)
.myclassname {width: 200px;}

<input type="text" name="test" class="myclassname">

Or you can have the stylesheet apply the class by default to inputs like this :

(in the stylesheet)
input { width:200px;}


However, I have found that it works more reliably if you use the first option and name the class as some browsers have trouble with applying a default style to certain types of form elements.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Have you ever sent email via ColdFusion and thought of tracking this mail to capture the exact date and time when the message was opened ?  If yes, then this article is for you ! First we need a table user_email with columns user_id , email , sub…
If you don't have the right permissions set for your WordPress location in IIS, you won't be able to perform automatic updates. Here's how to fix the problem.
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

920 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

13 Experts available now in Live!

Get 1:1 Help Now