I was trying to style a select but gave up for incompatibility issues with IE8 and Safari. So I thought to use a dropdown instead of the select and then another problem appeared. When a select is near the bottom of a page, the options appear above the select rather than the bottom, which is the default. What I want to know is if anyone has a solution using jQuery to make the dropdown options appear above it as the select options
<!DOCTYPE html>
<html lang="en">
<head>
<title>Dropdown Menu</title>
<meta charset="UTF-8">
<style type="text/css">
* {border: 0; margin: 0; padding: 0;}
div {
background-color: #09C;
width: 200px;
line-height: 40px;
bottom: 40px;
left: 300px;
display: block;
position: absolute;
text-indent: 15px;
cursor: pointer;
}
div span {
font-weight: bold;
font-family: sans-serif;
font-size: 16px;
color: #FFF;
}
div:hover ul {display: block;}
div ul {
background-color: #0f0;
width: 200px;
height: 300px;
position: absolute;
display: none;
list-style: none;
}
div ul li {
background-color: #000;
width: 200px;
line-height: 30px;
font-weight: bold;
font-family: sans-serif;
font-size: 16px;
color: #FFF;
}
</style>
</head>
<body>
<div>
<span>Dropdown</span>
<ul>
<li>Link 01</li>
<li>Link 02</li>
<li>Link 03</li>
<li>Link 04</li>
<li>Link 05</li>
<li>Link 06</li>
<li>Link 07</li>
<li>Link 08</li>
<li>Link 09</li>
<li>Link 10</li>
</ul>
</div>
</body>
</html>