Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/python/343.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
Python 为什么JavaScript无法在Centos上获取Django标记值,但它';这在Windows中很正常 #bk{ {%load staticfiles%} 背景图像:url({%static“1.gif”%}); 背景重复:否; 背景色:黄色;} 函数fresh() { document.getElementById(“bk”).src=“{%url”freshpic“%””; 警报(“新功能1”); }; 你好,我的第一个朋友 新鲜的_Python_Django_Python 3.x_Uwsgi - Fatal编程技术网

Python 为什么JavaScript无法在Centos上获取Django标记值,但它';这在Windows中很正常 #bk{ {%load staticfiles%} 背景图像:url({%static“1.gif”%}); 背景重复:否; 背景色:黄色;} 函数fresh() { document.getElementById(“bk”).src=“{%url”freshpic“%””; 警报(“新功能1”); }; 你好,我的第一个朋友 新鲜的

Python 为什么JavaScript无法在Centos上获取Django标记值,但它';这在Windows中很正常 #bk{ {%load staticfiles%} 背景图像:url({%static“1.gif”%}); 背景重复:否; 背景色:黄色;} 函数fresh() { document.getElementById(“bk”).src=“{%url”freshpic“%””; 警报(“新功能1”); }; 你好,我的第一个朋友 新鲜的,python,django,python-3.x,uwsgi,Python,Django,Python 3.x,Uwsgi,我无法在Centos上获得{%url'freshpic'}的响应,但在Windows上是正常的,{%static“1.gif”%}在两个操作系统上都是正常的。另外,我们使用Centos进行部署 6.6+uwsgi2.0.8+django1.7+Python3.4,有人有经验吗?谢谢在Windows上发布{%url'freshpic%}的值。当你在Windows/centos上说:你是在Windows和centos上托管你的应用程序还是在Windows/centos上连接客户端?回复:Foon我在

我无法在Centos上获得{
%url'freshpic'
}的响应,但在Windows上是正常的,{
%static“1.gif”%
}在两个操作系统上都是正常的。另外,我们使用
Centos进行部署

6.6+uwsgi2.0.8+django1.7+Python3.4
,有人有经验吗?谢谢

在Windows上发布
{%url'freshpic%}
的值。当你在Windows/centos上说:你是在Windows和centos上托管你的应用程序还是在Windows/centos上连接客户端?回复:Foon我在WIN或centos上托管我的应用程序,我使用双系统。我想可能是浏览器的问题。回复:nwk在WIN上正常运行,你不需要发布,django可以自动完成。
<style type="text/css">
#bk {
{% load staticfiles %}
background-image: url({% static "1.gif" %});
background-repeat: no;
background-color: yellow;}
</style>
<script type="text/javascript">
function fresh()
{
  document.getElementById("bk").src="{% url 'freshpic' %}";
  alert("fresh function1");
};
</script> 
</head>
<body id="bk">
   Hello My first Stackoverflow
 <button id='refresh' type="button" onclick="fresh()">FRESH</button>
 </body>