[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 196
  • Last Modified:

Size of input field and box

I have got an input field and a drop down box on my page (please see below). However, the default sizes of both are a bit to large.
My question: how can I make the input field and drop down box look smaller (less pixels high and wide) in Netscape and Internet Explorer?

<form>
<input type=text size=15>

<select>
<option value="link1.html">Link 1
<option value="link2.html">Link 2
<option value="link3.html">Link 3
</select>

</form>

Thanks
0
oud
Asked:
oud
1 Solution
 
MarineCommented:
change the widht to make it wider or shorter like you need it.
<SELECT id=select1 name=select1 style="HEIGHT: 22px; WIDTH: 277px"> <OPTION
  selected
  value="">aaaaaaaa</OPTION><OPTION
  value="">aaaaaaaaaa</OPTION><OPTION value="">ddfdf</OPTION><OPTION
  value="">dfdf</OPTION><OPTION value="">dfdf</OPTION><OPTION
value=""></OPTION></SELECT>

you can give a number between the the quote to keep track of the item selected.

<INPUT id=text1 name=text1
style="HEIGHT: 22px; WIDTH: 249px">

Same for the textbox needed more wider change the width
0
 
MarineCommented:
Here i took out the unneeded info from there in case you don't need it.

<SELECT name=select1
style="HEIGHT: 22px; WIDTH: 172px">
<OPTION>Link1</OPTION>
<option>Link2</Option>
<option>Link3</option>
</SELECT></P>

<INPUT id=text1 name=text1
style="HEIGHT: 22px; WIDTH: 249px">

you will probably be needing a <a> tag so when you select the droped down item you will be moved to the next page or something.

Just do this then.
<option><a href="link1.htm">Link1</a></option>
0
 
oudAuthor Commented:
Hi Marine,

This work well in Internet Explorer 4 but it doesn't change anything in Netscape 4. Is there a way to make it work in Netscape as well?

Thanks
0
The new generation of project management tools

With monday.com’s project management tool, you can see what everyone on your team is working in a single glance. Its intuitive dashboards are customizable, so you can create systems that work for you.

 
MarineCommented:
Darn, i can't test this in Netscape don't use that browser.
0
 
oudAuthor Commented:
Hi Marine,

This work well in Internet Explorer 4 but it doesn't change anything in Netscape 4. Is there a way to make it work in Netscape as well?

Thanks
0
 
MarineCommented:
Darn, i can't test this in Netscape don't use that browser.
0
 
oudAuthor Commented:
Just saw that Experts Exchange was kind enought to post my reply again :)

I will wait untill someone else replies. I will give you the points.. and another 175 points to anyone who can also make it work in Netscape.
0
 
MarineCommented:
i found an older version of netscape on my PC. I browsed some site to see how they have their html writen to see if it will work. See if this helps you.


<OPTION VALUE="http://www.pagelinx.com/bpjferry">Bridgeport to Port Jeff.

<OPTION VALUE="http://www.pagelinx.com/biferry">Viking Fleet

<OPTION VALUE="http://www.pagelinx.com/sayvferry">Sayville to F.I. Ferry

<OPTION VALUE="http://www.pagelinx.com/dpferry">Davis Park Ferry

<OPTION VALUE="http://www.pagelinx.com/sisferry">Shelter Island South

<OPTION VALUE ="Link1">Link1
<OPTION VALUE="Link2">Link2
<OPTION VALUE="Linke3">Link3
</OPTION>
</OPTION>
</OPTION>
</SELECT>

I don't know if this will work on IE. But i think you can write a small JavaScript which will see what browser you using and depending on that use this html to display it for Netscape and the other to display it on IE.
0
 
MarineCommented:
i found an older version of netscape on my PC. I browsed some site to see how they have their html writen to see if it will work. See if this helps you.



<Select>
<OPTION <OPTION VALUE ="Link1">Link1
<OPTION VALUE="Link2">Link2
<OPTION VALUE="Linke3">Link3
</OPTION>
</OPTION>
</OPTION>
</SELECT>

I don't know if this will work on IE. But i think you can write a small JavaScript which will see what browser you using and depending on that use this html to display it for Netscape and the other to display it on IE.
0
 
al162960Commented:
In netscape it may work (altough im not really sure) if you alter the properties of the text inside the select box using
<font size=-2>
<Select>
<OPTION <OPTION VALUE ="Link1">Link1
<OPTION VALUE="Link2">Link2
<OPTION VALUE="Linke3">Link3
</OPTION>
</OPTION>
</OPTION>
</SELECT>
</font>

its worth a shot  =)

cheers
0
 
cabrionetCommented:
This code will do it.

<html>
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style type="text/css">
<!--
..test {  font-family: Arial; font-size: 9pt; font-style: normal; font-weight: normal; font-variant: normal; text-decoration: none; }
-->
</style></head>



<body bgcolor="#FFFFFF">
<span class="test"></span>
<FORM class="test">

  <SELECT id=select1 name=select1 class="test">
    <OPTION selected value="">SMALL LINK</OPTION>
<OPTION value="">SMALL LINK</OPTION>
<OPTION value="">SMALL LINK</OPTION>
<OPTION value="">SMALL LINK</OPTION>
<OPTION value="">SMALL LINK</OPTION>
<OPTION value="">SMALL LINK</OPTION>
</SELECT>

 </FORM>

</body>
</html>

If you want smaller size... now you have size 9 (font-size: 9pt;). Put in the number 8... This code works on IE and NS 4+.

Good luck...

0
 
oudAuthor Commented:
As I said Marine: these 175 points are for you.

cabrionet: your option works, but I also have an input field in my form. The size of this field should also change (see my initial question). I have posted a "For cabrionet" question.

Hope you can help me with the field.
0
 
MarineCommented:
Thank you oud. Email me if you need other help at Crutoy@aol.com
0
 
oudAuthor Commented:
Ok, thanks Marine.
0

Featured Post

Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

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