Lea*_*ing 5 asp.net jquery jquery-ui
以下日期选择器在 asp.net 网络表单中不起作用。我多次更改代码,甚至其他示例都没有工作,甚至创建新页面进行测试仍然无法正常工作。
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="test.aspx.cs" Inherits="test" %>
<!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 runat="server">
<title></title>
<script src="http://ajax.googleapis.com/ajax/libs/jquery/1.6/jquery.min.js" type = "text/javascript"></script>
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js" type = "text/javascript"></script>
<link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel = "Stylesheet" type="text/css" />
<script type="text/javascript">
//Code Starts
$(document).ready(function() {
$('#Text1').datepicker();
$('#<%=txtBookDate.ClientID %>').datepicker();
});?
</script>
</head>
<body>
<form id="form1" runat="server">
<div>
<asp:TextBox ID="txtBookDate" runat="server"></asp:TextBox><input id="Text1" type="text" />
</div>
</form>
</body>
</html>
Run Code Online (Sandbox Code Playgroud)
jsFiddler 上的示例正在运行
在以下代码行的最后一个分号之后:
\n\n$(document).ready(function() {\n\n $('#Text1').datepicker();\n $('#<%=txtBookDate.ClientID %>').datepicker();\n});\xe2\x80\x8b\nRun Code Online (Sandbox Code Playgroud)\n\n你有某种狡猾的性格。删除它,你就可以开始了。
\n| 归档时间: |
|
| 查看次数: |
5055 次 |
| 最近记录: |