的DatePicker - 与链接
问题描述:
这里就是我在HtmlHelper类写道:的DatePicker - 与链接
html.Append("<script type=\"text/javascript\">$(document).ready(function() { $('#" + name + "').datepicker({ onSelect: openday,dateFormat: 'yymmdd' }); });");
html.Append("function openday(dateText, inst) { window.location = '" + link + "/' + encodeURIComponent(dateText); }</script>");
这里是从视图中调用:
<%Html.DatePicker("Date",Url.Action("Dropped","ProcessList"),this.ViewData["TheDate"]) %>
所以..当我点击的日期选择器第一次..一切正常.. 但问题是第二次点击:我得到follwing网址:ProcessList/Dropped/20110416/20110401
我能做什么? 感谢您的支持!