Return to Snippet

Revision: 4263
at November 14, 2007 11:27 by victorchamorro


Initial Code
INSIDE THE HEAD
......................................................................
<script type="text/javascript" src="http://brandonaaron.net/jquery/plugins/bgiframe/jquery.bgiframe.js"></script>

<script type="text/javascript">
  $(function() {
    $('#box').bgiframe();
  });
</script>

<style type="text/css" media="screen">
  form { position: absolute; top: 0; left: 0; width: 100%; }
  select { position: relative; width: 100%; margin: 0 0 2px; z-index: 1; }
  .box { position: relative; z-index: 2; float: left; margin: 5px; border: 5px solid #666; padding: 5px; width: 250px; height: 100px; color: #000; background-color: #999; }
</style>
 

HTML
......................................................................
<form action="#" method="get" accept-charset="utf-8">
  <select name="test"><option>valor 1</option></select>
  <select name="test"><option>valor 2</option></select>
  <select name="test"><option>valor 3</option></select>
</form>
<div id="box" class="box">contenido del box</div>

Initial URL

                                

Initial Description
using bgiframe to solve a bug in explorer: you cannot apply z-index to place divs over selects in a form!!!

Initial Title
jquery: simule z-index to place divs over select objects (explorer bug)

Initial Tags
form

Initial Language
JavaScript