Solved

Select Object Size

Posted on 1998-08-20
3
171 Views
Last Modified: 2010-04-09
It seems to me that the size of a selec object depends of the size of the largest option it contains.
Can I assign a different size of the select ? ?
0
Comment
Question by:carflores
  • 2
3 Comments
 
LVL 1

Accepted Solution

by:
evilgreg earned 50 total points
ID: 1836860
Nope. You /can/ do some funky stuff with the OPTGROUP element, but HTML does not allow for control of the maximum size of the rows. Which is probably a good thing - why cut off your longest entry?

Of course, you could change the size with Java, but that's not really HTML anymore....

(If you are specifically trying to acheive something, let us know - there may be a workaround)

0
 

Author Comment

by:carflores
ID: 1836861
I don´t want to cut off the longest entry, contrarily I want to make the select bigger than the longest entry
0
 
LVL 1

Expert Comment

by:evilgreg
ID: 1836862
You can make the introductory item extra large:

<SELECT>
<OPTION SELECTED>-----Please choose from the following---
<OPTION>Monday
<OPTION>Tuesday
<OPTION>Wednesday
etc...

Or you can use the non-breaking space entity - it's ugly, but it works:

<OPTION>Two
<OPTION>
&nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp;
<OPTION> Three

Put a space between each one for an added effect.

0

Featured Post

Live: Real-Time Solutions, Start Here

Receive instant 1:1 support from technology experts, using our real-time conversation and whiteboard interface. Your first 5 minutes are always free.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
Delete HTML table rows 12 28
HTML5 frame 5 25
Create CSS Animation for Page Transitions 4 26
Mouse event to control image and transparency. 4 19
Finding original email is quite difficult due to their duplicates. From this article, you will come to know why multiple duplicates of same emails appear and how to delete duplicate emails from Outlook securely and instantly while vital emails remai…
The article shows the basic steps of integrating an HTML theme template into an ASP.NET MVC project
In this tutorial viewers will learn how to position overlapping items using z-index in CSS. They will also learn the restrictions on the z-index property.  Create a new HTML document with an internal stylesheet.: Create a div in CSS and name it Red.…
In this tutorial viewers will learn how to code links for mobile sites that, once clicked, send a call or text to a specified number. For a telephone link (once clicked, calls a number), begin with a normal "<a href=" link tag. For the href, specify…

776 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