Tycoon Talk
Become a Big fish!
The number 1 forum for online business!
Post topics, ask questions, share your knowledge.
Tycoon Talk is part of Freelancer.com - find skilled workers online at a fraction of the cost.

HTML Forum


You are currently viewing our HTML Forum as a guest. Please register to participate.
Login



Post a Project »

Find a Professional HTML Freelancer!

Find a Freelancer to help you with your HTML projects

FREE Outsourcing eBook!

Reply
fixed <select> widths
Old 07-23-2005, 05:47 AM fixed <select> widths
purk's Avatar
Extreme Talker

Posts: 164
Name: James
Location: marbella & surrey
Trades: 0
i have a fixed width drop-down, the width is fixed in the elements style attribute.
what i want is to have the width of the list area (which appears onclick) to be big enough to show the entire value of the labels in the <option>'s when they are longer than the width of the drop-down when in it's initial state, that is to say not dropped-down.
purk is offline
Reply With Quote
View Public Profile Visit purk's homepage!
 
 
Register now for full access!
Old 07-23-2005, 07:12 AM
Enigmatic's Avatar
Registered User

Posts: 86
Location: No Fixed Abode
Trades: 0
Not sure on this one myself but try using CSS and width: auto;
Enigmatic is offline
Reply With Quote
View Public Profile
 
Old 07-23-2005, 07:24 AM
purk's Avatar
Extreme Talker

Posts: 164
Name: James
Location: marbella & surrey
Trades: 0
putting
HTML Code:
width:auto
in the style attribute of the select elemt seems to have had no effect at all. been trawling the net for an answer for this with no luck for a few days now.
purk is offline
Reply With Quote
View Public Profile Visit purk's homepage!
 
Old 07-23-2005, 08:30 AM
Enigmatic's Avatar
Registered User

Posts: 86
Location: No Fixed Abode
Trades: 0
##----[ HEADER ELEMENT ]----##
<style type="text/css">
.selectWidth {
width: auto;
}
</style>

##----[ BODY ELEMENT ]----##
<select class="selectWidth"> ... </select>

Is that how you did it ?
Enigmatic is offline
Reply With Quote
View Public Profile
 
Old 07-23-2005, 08:50 AM
purk's Avatar
Extreme Talker

Posts: 164
Name: James
Location: marbella & surrey
Trades: 0
it wasn't, i just had <select style="width:30px"> or 'auto' in place of '30px'.
i have just tried your css exactly and in IE it does nowt.

what's most annoying is that i have seen done what i need but can't remember where i saw it. grr
purk is offline
Reply With Quote
View Public Profile Visit purk's homepage!
 
Old 07-23-2005, 10:38 AM
Enigmatic's Avatar
Registered User

Posts: 86
Location: No Fixed Abode
Trades: 0
IE is balls, the CSS is use on my site works fine in ever browser BUT IE.
Enigmatic is offline
Reply With Quote
View Public Profile
 
Reply     « Reply to fixed <select> widths
 

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off





   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML



Page generated in 0.69924 seconds with 12 queries