Created
January 14, 2011 15:45
-
-
Save tvdeyen/779759 to your computer and use it in GitHub Desktop.
Example for the calculated width of an select element.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<html> | |
<head> | |
<script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/jquery/1.4.4/jquery.min.js"></script> | |
<script type="text/javascript" src="https://github.com/revsystems/jQuery-SelectBox/raw/master/jquery.sb.min.js"></script> | |
<link type="text/css" rel="stylesheet" media="screen" href="https://github.com/revsystems/jQuery-SelectBox/raw/master/jquery.sb.css"> | |
<style type="text/css" media="screen"> | |
select.long { | |
width: 150px; | |
} | |
a.display.long { | |
width: 150px; | |
} | |
</style> | |
</head> | |
<body> | |
<table> | |
<tr> | |
<td> | |
<label for="public_filename">File</label> | |
</td> | |
<td> | |
<select name="public_filename" class="long"> | |
<option value="/attachment/4/download?name=stimmhaus_anmeldung-agb_stimme-und-persoenlichkeit_seminare-coaching.pdf">stimmhaus_anmeldung-agb_stimme-und-persoenlichkeit_seminare-coaching.pdf</option> | |
<option value="/attachment/5/download?name=HR1_Interview-zu-Stimme_Stimmpers_nlichkeit-anlaesslich-Stimmabgabe-Hessen-20090118-Waibel-Stimmhaus.mp3">HR1_Interview-zu-Stimme_Stimmpers_nlichkeit-anlaesslich-Stimmabgabe-Hessen-20090118-Waibel-Stimmhaus.mp3</option> | |
</select> | |
</td> | |
</tr> | |
</table> | |
<script type="text/javascript" charset="utf-8"> | |
jQuery('select').sb({animDuration: 0, fixedWidth: false}); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment