0
我無法弄清楚這一點,我已經嘗試了JavaScript的每一個片段,我可以找到哪些據稱阻止移動Safari瀏覽器中的鏈接窗口打開,但沒有人在我的coldfusion webapp獨立模式下工作。在網絡模式下,它一切正常。如何阻止在Safari中打開ColdFusion目標?
鏈接
<a class="button" href="rptSectors_bar.cfm" target="mainwindow">
代碼我已經試過:
<script>
function init() {
$("a").click(function(e) { $("#content").load(e.target.href);return false; });
}
$(document).ready(init);
</script>
第二個:
<script>
if (window.navigator.standalone) {
$(document).on(
"click",
"a",
"button,"
function (event) {
event.preventDefault();
var aurl = $(event.target).attr("href");
if (aurl) {
location.href = $(event.target).attr("href");
}
else {
location.href = this;
alert(this);
}
}
);
}
</script>
感謝您的幫助提前
沒有具體的幫助,但是確實是一個很好的證明我是在正確的道路上。我最終得到了一個解決方案。謝謝! – NessyString 2013-03-16 06:40:47