Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/qt/6.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Gnuplot 莫乔利斯不';t加载绝对javascript和CSS文件_Gnuplot_Mojolicious - Fatal编程技术网

Gnuplot 莫乔利斯不';t加载绝对javascript和CSS文件

Gnuplot 莫乔利斯不';t加载绝对javascript和CSS文件,gnuplot,mojolicious,Gnuplot,Mojolicious,我正在尝试使用Gnuplot创建“canvas”HTML文档。当我把一个放到public/中时,Mojolicious在/usr/share/gnuplot/gnuplot/5.2/js中的javascript和CSS文件上生成404。在不修改HTML输出的情况下,如何正确加载这些文件 HTML内容: <!DOCTYPE HTML> <html> <head> <title>Gnuplot Canvas Graph</title> &l

我正在尝试使用Gnuplot创建“canvas”HTML文档。当我把一个放到public/中时,Mojolicious在/usr/share/gnuplot/gnuplot/5.2/js中的javascript和CSS文件上生成404。在不修改HTML输出的情况下,如何正确加载这些文件

HTML内容:

<!DOCTYPE HTML>
<html>
<head>
<title>Gnuplot Canvas Graph</title>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
<!--[if IE]><script type="text/javascript" src="excanvas.js"></script><![endif]-->
<script src="/usr/share/gnuplot/gnuplot/5.2/js/canvastext.js"></script>
<script src="/usr/share/gnuplot/gnuplot/5.2/js/gnuplot_common.js"></script>
<script src="/usr/share/gnuplot/gnuplot/5.2/js/gnuplot_dashedlines.js"></script>
...
</html>

我知道它正在将这些文件路径转换为URL,但我不知道如何解决这个问题。

gnuplot canvas终端有一个选项“jsdir”,正是出于这个原因:

gnuplot> set term canvas jsdir 'http://wherever/the/scripts/live/'
然后,输出*.html包含如下行

<!--[if IE]><script type="text/javascript" src="excanvas.js"></script><![endif]-->
<script src="http://wherever/the/scripts/live/canvasmath.js"></script>
<script src="http://wherever/the/scripts/live/gnuplot_common.js"></script>
<script src="http://wherever/the/scripts/live/gnuplot_dashedlines.js"></script>
<script src="http://wherever/the/scripts/live/gnuplot_mouse.js"></script>

自我提示:RTFM!
<!--[if IE]><script type="text/javascript" src="excanvas.js"></script><![endif]-->
<script src="http://wherever/the/scripts/live/canvasmath.js"></script>
<script src="http://wherever/the/scripts/live/gnuplot_common.js"></script>
<script src="http://wherever/the/scripts/live/gnuplot_dashedlines.js"></script>
<script src="http://wherever/the/scripts/live/gnuplot_mouse.js"></script>