下拉列表框的隐藏和显示_Android, Python及开发编程讨论区_Weblogic技术|Tuxedo技术|中间件技术|Oracle论坛|JAVA论坛|Linux/Unix技术|hadoop论坛_联动北方技术论坛  
网站首页 | 关于我们 | 服务中心 | 经验交流 | 公司荣誉 | 成功案例 | 合作伙伴 | 联系我们 |
联动北方-国内领先的云技术服务提供商
»  游客             当前位置:  论坛首页 »  自由讨论区 »  Android, Python及开发编程讨论区 »
总帖数
1
每页帖数
101/1页1
返回列表
0
发起投票  发起投票 发新帖子
查看: 1882 | 回复: 0   主题: 下拉列表框的隐藏和显示        下一篇 
    本主题由 koei123 于 2015-7-14 11:05:49 移动
Michelle
注册用户
等级:列兵
经验:88
发帖:58
精华:0
注册:2011-8-11
状态:离线
发送短消息息给Michelle 加好友    发送短消息息给Michelle 发消息
发表于: IP:您无权察看 2015-7-10 10:09:30 | [全部帖] [楼主帖] 楼主

<script language="javascript">

 

function show_ji(){

       document.getElementById('div1').style.visibility="visible";

}

function hide_ji(){

       document.getElementById('div1').style.visibility="hidden";

 

}

function show_yue(){

       document.getElementById('div2').style.visibility="visible";

 

}

function hide_yue(){

       document.getElementById('div2').style.visibility="hidden";

 

}

function show_ri(){

       document.getElementById('div3').style.visibility="visible";

 

}

function hide_ri(){

       document.getElementById('div3').style.visibility="hidden";

 

}

function together()

{

       if(document.form1.baobiaoleixing.value==001)

       {

              hide_ji();

              hide_yue();

              hide_ri();

       }

      

       if(document.form1.baobiaoleixing.value=="002")

       {

             

              hide_yue();

              hide_ri();

              show_ji();

 

       }

       if(document.form1.baobiaoleixing.value==003)

       {

              hide_ji();

              show_yue();

              hide_ri();

       }

       if(document.form1.baobiaoleixing.value==004)

       {

              hide_ji();

              show_yue();

              show_ri();

       }

      

 

}

</script>

 

</head>

<body style="overflow-x:hidden;overflow-y:auto">

<form name="form1">

 

 

<select name="baosongleixing">

                    <option>报送公安部 </option>

                    <option>报送市政府 </option>

                    <option>报送市公安局 </option>

                    <option>内部使用</option>

                  </select> &nbsp;&nbsp;

                             

                             <select name="year">

                    <option>2000</option>

                    <option>2001</option>

                    <option>2002</option>

                    <option>2003</option>

                    <option>2004</option>

                    <option>2005</option>

                    <option>2006</option>

                    <option>2007</option>

                    <option>2008</option>

                    <option>2009</option>

                  </select>

                  年 &nbsp;&nbsp;

                             

                             <select name="baobiaoleixing" onchange="together()">

                    <option value="001">年报表</option>

                    <option value="002">季报表</option>

                    <option value="003">月报表</option>

                    <option value="004">日报表</option>

                  </select>

                  </td>

                               <!--***************************************-->

                  <td class="txt" width="10%">

                  <div id="div1" style="visibility='hidden'">

                                                  

                     <select name="season" >

                    <option>第一季度</option>

                    <option>第二季度</option>

                    <option>第三季度</option>

                    <option>第四季度</option>

                  </select>

                 

                  </div>

                  </td>

                <!--***************************************-->

                   <td class="txt" width="10%">

                  <div id="div2" style="visibility='hidden'">

                   <select name="month" >

                   <option>1</option>

                   <option>2</option>

                   <option>3</option>

                   <option>4</option>

                   <option>5</option>

                   <option>6</option>

                   <option>7</option>

                   <option>8</option>

                   <option>9</option>

                   <option>10</option>

                   <option>11</option>

                   <option>12</option>

                  </select>

                  月

                  </div>

                  </td>

                   <!--***************************************-->

                             <td class="txt" width="10%">

                  <div id="div3" style="visibility='hidden'">

                    <select name="day" >

                   <option>1</option>

                   <option>2</option>

                   <option>3</option>

                   <option>4</option>

                   <option>5</option>

                   <option>6</option>

                   <option>7</option>

                   <option>8</option>

                   <option>9</option>

                   <option>10</option>

                   <option>11</option>

                   <option>12</option>

                   <option>13</option>

                   <option>14</option>

                   <option>15</option>

                   <option>16</option>

                   <option>17</option>

                   <option>18</option>

                   <option>19</option>

                   <option>20</option>

                   <option>21</option>

                   <option>22</option>

                   <option>23</option>

                   <option>24</option>

                   <option>25</option>

                   <option>26</option>

                   <option>27</option>

                   <option>28</option>

                   <option>29</option>

                   <option>30</option>

                   <option>31</option>

                          </select>

                  日

                  </div>

                  </td>

                             <!--***************************************-->  

--转自 北京联动北方科技有限公司



该贴由koei123转至本版2015-7-14 11:05:49



赞(0)    操作        顶端 
总帖数
1
每页帖数
101/1页1
返回列表
发新帖子
请输入验证码: 点击刷新验证码
您需要登录后才可以回帖 登录 | 注册
技术讨论