如何做像51job那样弹出层,选择省 城市的代码?

解决方案 »

  1.   

    如果你要简单的可以用Ext的windows窗口代替,,无视浏览器。。
    function _getWindow() {
        
      win = new Ext.Window({
        title: arguments[3],
        modal :true,
        collapsible:true,
        closeAction:"close",//点击右上角X关闭时如果不指定此属性,再次点击时将无法创建窗口
        html:"<iframe src='"+arguments[0]+"' width=\"100%\" height=\"100%\"></iframe>",
        layout:'fit',
        width:arguments[1],
        height:arguments[2],
        plain: true,
        maximizable:true                       
      });
      win.show(document.body);}
      

  2.   

    <html>
    <head>
        <script>
    function tableClicked(e)
    {
    //e=e?e:window.event;
    document.getElementById("ms").value=(e.srcElement?e.srcElement.innerHTML:e.target.textContent);
    document.all.Layer2.style.display='none';
    document.all.ly.style.display="none";
    }
      function locking(){   
      document.all.ly.style.display="block";   
      document.all.ly.style.width=document.body.clientWidth;   
      document.all.ly.style.height=document.body.clientHeight;   
      document.all.Layer2.style.display='block';   
      }     
        </script></head>
    <body>
     <input id="ms" type="text"/>
         <input type="button" value="查询" onclick="locking()">
        <div id="ly" style="position: absolute; top: 0px; filter: alpha(opacity=60); background-color: #777;
            z-index: 2; left: 0px; display: none;">
        </div>
        <!--浮层框架开始-->
        <div id="Layer2" align="center" style="position: absolute; z-index: 10; left: expression((document.body.offsetWidth-540)/2); top: expression((document.body.offsetHeight-170)/2);
            background-color: #fff; display: none;" >
            <table width="540" border="0" cellpadding="0" cellspacing="0" style="border: 0   solid   #e7e3e7;
                border-collapse: collapse">
    <caption>
    <div align="left" style="background-color: #73A2d6; color: #fff; padding-left: 4px; padding-top: 2px;
    font-weight: bold; font-size: 14px;" width="100%" height="20" valign="middle">
    IP 选择
    </div>
    </caption>
    <table width="" onclick="tableClicked(event)">
    <tbody align="left">
    <tr>
    <td>192.168.0.1</td> 
    <td>192.168.0.2</td>
    <td>192.168.0.3</td>
    <td>192.168.0.4</td>
    </tr>
    </tbody>
    </table>
            </table>
        </div>
        <!--浮层框架结束-->
    </body>
    </html>
      

  3.   

    http://www.lanrentuku.com/js/form-53.html参考上面的
      

  4.   

    6楼的,那个选择好了的,城市 要是传给ASP,该如何读取啊?