问题描述
我有问题。我在heroku上托管了一个网站。当我打开文件(index.html)时,本地ID正常加载(与图标相同),但是当我进入网站时,它不起作用。该网站的脚本是:
<html>
<style>
some style here
<style>
<head>
<title>Site</title>
<link rel="shortcut icon" type="image/png" href="icon.png">
</head>
<body>
<img src="logo.png">
other body
</body>
</html>
托管主机是(node.js):
var http = require("http");
var PORT = process.env.PORT || 5000;
fs = require('fs');
fs.readFile('./index.html',function (err,html) {
if (err) {
throw err;
}
http.createServer(function(request,response) {
response.writeHeader(200,{"Content-Type": "text/html"});
response.write(html);
response.end();
}).listen(PORT);
});
procfile是:
web: node main.js
本地图像(和图标加载)
但是在heroku上它显示了这一点
对于图标: picturetwo
如果您需要更多信息,请发表评论。
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)