简体   繁体   English

如何链接到不同计算机上的静态Html页面。

[英]How to link to static Html page on a different machine.

we have a internal tool a web php app we use . 我们有一个内部工具我们使用的web php应用程序。 There are some static html files i want to link it to, which are on another machine . 我想将一些静态html文件链接到另一台机器上。 right now i am doing like this 现在我这样做

<a href="file:////123.145.226.8/Projects/E-Reports/E-Report-' . $projectNo . '/Report.html" target="_blank">E-Report</a>

which works just fine in IE !!!!!!!!!!!!!!!!! 哪个在IE中工作得很好!!!!!!!!!!!!!!!!! but not in firefox any ideas ? 但是在firefox中没有任何想法? This is a internal tool so the machine on which static files are present is always available. 这是一个内部工具,因此存在静态文件的机器始终可用。 thanks 谢谢

You should install a webserver on the machine 123.145.226.8 . 您应该在计算机123.145.226.8上安装Web服务器。 If it's a Windows machine, try xampp and place the files in the htdocs directory. 如果是Windows机器,请尝试xampp并将文件放在htdocs目录中。 Now you can visit the HTML page with http://123.145.226.8 . 现在,您可以访问http://123.145.226.8的HTML页面。

If it's running linux, use apt-get install apache2 or yum install httpd (depending on operating system) and place your files in /var/www/ . 如果它正在运行linux,请使用apt-get install apache2yum install httpd (取决于操作系统)并将文件放在/var/www/

Unfortunately this is the default behavior for Firefox. 不幸的是,这是Firefox的默认行为。 You must configure the browser manually. 您必须手动配置浏览器。 See this thread 看到这个帖子

Firefox Links to local or network pages do not work Firefox链接到本地​​或网络页面不起作用

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

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