JavaScript实现popup日期控件(三)

来源:互联网 发布:mysql的日期函数 编辑:程序博客网 时间:2024/05/17 20:34

应用 

 

<table>
    
<tbody>
        
<tr>
            
<td><input class="button" onclick="alert(DateSam.getDateStr())" type="button" value="得到时间" /></td>
            
<td><input class="button" onclick="DateSam.setTimeShow(!DateSam.showTime)" type="button" value="设置显示时间" /></td>
            
<td><input class="button" onclick="DateSam.setReadonly(!DateSam.readonly)" type="button" value="设置只读" /></td>
            
<td style="WIDTH: 100%">&nbsp;</td>
        
</tr>
        
<tr>
            
<td style="WIDTH: 100%" colspan="4"><input class="button" onclick="DateSam.updateDateTime(StringToDate(document.getElementById('inputDate').value));" type="button" value="设置时间(yyyy-mm-dd hh24:mi:ss)" /> <input id="inputDate" value="2005-12-23 12:34:00" /> </td>
        
</tr>
        
<tr>
            
<td style="WIDTH: 100%" valign="top" colspan="4"><SCRIPT
                
language="JavaScript">
                
var DateSam = new BSDate("DateSam""elm_DateSam");
                DateSam.updateTime(
0000);
                DateSam.show();
            
</SCRIPT></td>
        
</tr>
    
</tbody>
</table>
原创粉丝点击