梦幻之旅

DEBUG - 天道酬勤

   :: 首页 :: 新随笔 :: 联系 :: 聚合  :: 管理 ::
  671 随笔 :: 6 文章 :: 256 评论 :: 0 Trackbacks
<td width="100"><input type="text" name="dataAddByManualReq.SSubscrMonth" id="SSubscrMonth" onclick="javascript:document.getElementById('monthDiv').style.display='';" class="text" readonly/><br/><div id="monthDiv" style='position:absolute; width:40; height:60;z-index:100;background:red; display:none;'>
                                            
<table>
                                                
<tr>
                                                    
<td colspan="4" style="text-align:right;"><onclick="javascript:document.getElementById('monthDiv').style.display='none';" style="cursor:pointer;">关闭</a></td>
                                                
</tr>
                                                
<tr>
                                                    
<td><input type="checkBox" name="huyMonth" value="1月"/>1月</td>
                                                    
<td><input type="checkBox" name="huyMonth" value="2月"/>2月</td>
                                                    
<td><input type="checkBox" name="huyMonth" value="3月"/>3月</td>
                                                    
<td><input type="checkBox" name="huyMonth" value="4月"/>4月</td>
                                                
</tr>
                                                
<tr>
                                                    
<td><input type="checkBox" name="huyMonth" value="5月"/>5月</td>
                                                    
<td><input type="checkBox" name="huyMonth" value="6月"/>6月</td>
                                                    
<td><input type="checkBox" name="huyMonth" value="7月"/>7月</td>
                                                    
<td><input type="checkBox" name="huyMonth" value="8月"/>8月</td>
                                                
</tr>
                                                
<tr>
                                                    
<td><input type="checkBox" name="huyMonth" value="9月"/>9月</td>
                                                    
<td><input type="checkBox" name="huyMonth" value="10月"/>10月</td>
                                                    
<td><input type="checkBox" name="huyMonth" value="11月"/>11月</td>
                                                    
<td><input type="checkBox" name="huyMonth" value="12月"/>12月</td>
                                                
</tr>
                                                
<tr>
                                                    
<script type="text/javascript">
                                                        
function addMonth()
                                                        
{
                                                            
var checkBoxArr = document.getElementsByName("huyMonth");
                                                            
                                                            
var monthStr = "";
                                                            
for(var i=0; i<checkBoxArr.length; i++)
                                                            
{
                                                                
if(checkBoxArr[i].checked)
                                                                
{
                                                                    monthStr 
+= "," + checkBoxArr[i].value;
                                                                }

                                                            }

                                                            
                                                            
if(monthStr.length>0)
                                                            
{
                                                                monthStr 
= monthStr.substr(1);
                                                            }

                                                            document.getElementById(
"SSubscrMonth").value=monthStr;
                                                        }

                                                    
</script>
                                                    
<td colspan="4" style="text-align:center;"><onclick="javascript:addMonth()" style="cursor:pointer;">确定</a></td>
                                                
</tr>
                                            
</table>
                                        
</div></td>
posted on 2010-02-02 19:01 HUIKK 阅读(716) 评论(0)  编辑  收藏 所属分类: Html

只有注册用户登录后才能发表评论。


网站导航: