简体   繁体   English

Xqib Hello World无法正常工作

[英]Xqib Hello World not working

I am trying implement basics examples of xquery but having problem whit Hello World. 我正在尝试实现xquery基础示例,但在Hello World方面遇到问题。 I have downloaded and placed mxqueryjs.nocache.js file correctly, so I don't know where is problem. 我已经正确下载并放置了mxqueryjs.nocache.js文件,所以我不知道问题出在哪里。

Here is my code: 这是我的代码:

<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">  
    <title>HelloWorld</title>
    <meta charset="UTF-8"/>
    <script type="text/javascript" src="mxqueryjs/mxqueryjs.nocache.js"></script>
    <script type="application/xquery">
       b:alert("Hello World")
    </script>
  </head>
  <body>
    <h1>Hello world page.</h1>
  </body>
</html>

Console output: 控制台输出:

Uncaught SecurityError: Blocked a frame with origin "null" from accessing a frame with origin "null". Protocols, domains, and ports must match. 6182B2DC971F7A2C7AEDC4F09F2BAE2D.cache.html:1
(anonymous function) 6182B2DC971F7A2C7AEDC4F09F2BAE2D.cache.html:1
Uncaught SecurityError: Blocked a frame with origin "null" from accessing a frame with origin "null". Protocols, domains, and ports must match. 6182B2DC971F7A2C7AEDC4F09F2BAE2D.cache.html:2867
(anonymous function)

This should open alert dialog and say Hello World, but it does nothing. 这应该打开警报对话框并说“ Hello World”,但是它什么也没做。 Online example is here: xqib - HelloWorld 在线示例在这里: xqib-HelloWorld

Xqib home page Xqib主页

Thanks 谢谢

您将需要下载以下模块: www.xqib.org/js/module.xquery并使用脚本标签将其导入:

script type="application/xquery" src="path_to/module.xquery"

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM