问题
I installed Wordpress on my station and its now being used internally for corporate blogging. I wanted to know if there is a way to create links to servers in our intranet?
For example to access a server resource in windows I use Run->\server-name\folder\file.txt
How can I create a link to such file in Excel (or generally in HTML) that will be opened by Firefox & IE when clicked in Wordpress.
Thanks,
Roy
回答1:
You can either map the servers to virtual hosts on the web server and create links like you would to any external file on the internet. Or, if you insist, use
<a href="file:///path/to/file.html">file</a>
in your example:
<a href="file:///server-name/folder/file.txt">file</a>
回答2:
After checking this, the right way to mimic a UNC form (at least in my case) was:
<a href="file://///server-name/folder/file.txt">file</a>
which is equal to
\\server-name\folder\file.txt
It works in Firefox (3.6) and IE (8).
We use Windows XP, all stations are in an Active Directory domain, in case it matters.
来源:https://stackoverflow.com/questions/5497169/how-to-create-a-link-in-wordpress-to-a-file-on-an-local-network-server