By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
449,243 Members | 1,116 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 449,243 IT Pros & Developers. It's quick & easy.

<select> element problem inside popup

P: 1
Hello. I have a small problem, here's code:

[HTML]<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>iframe popup (JS)</title>
<link href="style.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div align="center" style="width:">
some text---------------------------------------------------------------------------------;<br/>
some text---------------------------------------------------------------------------------;<br/>
<!-- Code -->
<div class="button">Move your corsor over here
<div style="display:block; position:relative"><!-- Use this div to show Frame under our button. Also we can use <iframe></iframe> --></div>
<!-- Frame content -->
<div class="frame">
<form action="test.php" method="post" name="coolstf">
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><img src="logo01.jpg" alt="Logo Test" /></td>
<td align="left">Some text; Some text; Some text;</td>
</tr>
</table>
<table width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td align="center">Header</td>
</tr>
<tr>
<td align="center">Please select:&nbsp;&nbsp;&nbsp;<select name="select"><option value="0" selected="selected">All</option><option value="1">1</option><option value="2">2</option></select></td>
</tr>
<tr>
<td align="center">Please enter:&nbsp;&nbsp;&nbsp;<input name="text1" type="text" maxlength="16" /></td>
</tr>
<tr>
<td align="center">Please choose:&nbsp;&nbsp;&nbsp;<input name="r1" type="radio" value="" /><input name="r1" type="radio" value="" /><input name="r1" type="radio" value="" /><input name="r1" type="radio" value="" /></td>
</tr>
<tr>
<td align="center">Please check:&nbsp;&nbsp;&nbsp;<input name="c1" type="checkbox" value="" /></td>
</tr>
<tr>
<td>&nbsp;</td>
</tr>
</table>
<br/>
<input name="submit" type="submit" value="PROCEED" />
</form>
</div>
<!-- -->
</div>
<!-- -->
some text---------------------------------------------------------------------------------;<br/>
some text---------------------------------------------------------------------------------;<br/>
</div>
</body>
</html>
[/HTML]
CSS:

Expand|Select|Wrap|Line Numbers
  1. @charset "utf-8";
  2. .button {
  3.     margin: 0px;
  4.     padding: 0px;
  5.     text-align: left;
  6.     width: 180px;
  7.     background-color: #CCCCCC;
  8. }
  9.  
  10. .button:hover  .frame {
  11.     visibility: visible;
  12. }
  13. .frame {
  14.     display: block;
  15.     visibility: hidden;
  16.     background-color: #FFFFFF;
  17.     border: 1px solid #000000;
  18.     position: absolute;
  19.     padding: 5px;
  20.     width: 250px;
  21.     height: auto;
  22. }
  23. .frame:hover {
  24.     visibility: visible;
  25. }
  26.  
  27.  
And my problem is when i try to select an option from <select> element my popup disapears in ie7. Works fine for FireFox and Opera. Thanks.
Jul 4 '08 #1
Share this Question
Share on Google+
1 Reply


acoder
Expert Mod 15k+
P: 16,027
You may need to use JavaScript here. Also, you should use a strict doctype to avoid going into quirks mode.
Jul 16 '08 #2

Post your reply

Sign in to post your reply or Sign up for a free account.