一个页面中使用了datetimepicker标签,结果浏览器提示了js错误:dojo未定义
下面是页面代码:
<s:form name="form1" method="post" action="create_user" theme="simple">
<s:datetimepicker name="userAdmin.birthday" displayFormat="yyyy-MM-dd"/>
<s:form>
找到了解决办法:在页面的<head>标签中加入<s:head /> 如下:
<head>
<title>Struts 2 Cool Tags - Others</title>
.....
<s:head />
</head>
再运行就是漂亮的日期选择界面了
相关资源:敏捷开发V1.0.pptx