我正在尝试在带有HTML服务的Google Apps脚本上使用jQuery datepicker。
Code.gs
function doGet() {
var template = HtmlService
.createTemplateFromFile('Page');
var htmlOutput = template.evaluate()
.setSandboxMode(HtmlService.SandboxMode.NATIVE)
.setTitle('Test Me');
return htmlOutput;
}
page.html中
<link rel="stylesheet" href="//ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/themes/smoothness/jquery-ui.css" />
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.11.0/jquery.min.js"></script>
<script src="//ajax.googleapis.com/ajax/libs/jqueryui/1.10.4/jquery-ui.min.js"></script>
<script>
$(function() {
$( "#datepicker" ).datepicker();
});
</script>
<div>
<p>Date: <input type="text" id="datepicker"></p>
</div>
托管脚本
https://script.google.com/d/1CWo9EonsNtS7Q4nYrhIWmtniMqnsUmWcxyusheGV5EO1EwEwNmPXCvzx/edit
的webapp
https://script.google.com/macros/s/AKfycbzCSzU6ErMtizMWvI5hBI1TIX0Fhj86_OTyvD16rdDM4jCk1obn/exec
一切都适用于Firefox和Chrome。但是当我点击Safari上的输入字段时,浏览器崩溃了。有什么见解吗?