0

我会参考具有 html 文件的实习生文件服务器上的链接。我的代码如下所示:

<a href="file://///192.168.115.203/fileserver/v_collection/search.html" target="_blank">
 <table class="linkTable">
  <tr class="linkTableLine">
   <td class="linkTxtCell">Icon Experience V-Collection</td>
  </tr>
 </table>
</a>

服务器可以在我们的实习生网络中访问,如果我复制链接并将其插入浏览器栏中,它就可以工作。但是,如果我单击 HTML 文件中的按钮,它什么也不做。我在 Chrome、Mozilla 和 IE 中尝试过。搜索后,我发现了一些旧线程,这些线程到最后,由于安全准则,浏览器不会打开本地文件。但以我的方式,它只显示来自其他服务器的 html 文件。HTML-File 不能被复制到 html-server 因为有更多的文件要在其中搜索。

我可以解决我的问题还是无法解决?

编辑:我尝试测试代码并且它有效。但在我的 php 创建的站点中,它不起作用。我会给你整张桌子:

<table class="links" cellspacing="5px">
<tr>
<td class="link">
<a href="file://///192.168.115.203/fileserver/Icons/IconExperience/v_collection/search.html" target="_blank"><table class="linkTable">
<tr class="linkTableLine">
<td class="linkTxtCell">
Icon Experience V-Collection
</td>
</tr>
</table>
</a>
</td>
</tr>
</table>

和CSS:

.link {
    font-weight: normal;
    border-width: 1px;
    border-style: solid;
    border-color: #303030;
    max-height: 23px;
    background: #e2e2e2; /* Old browsers */
    background: -moz-linear-gradient(top, #e2e2e2 0%, #dbdbdb 50%, #d1d1d1 51%, #fefefe
        100%); /* FF3.6+ */
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, #e2e2e2),
        color-stop(50%, #dbdbdb), color-stop(51%, #d1d1d1),
        color-stop(100%, #fefefe) ); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(top, #e2e2e2 0%, #dbdbdb 50%, #d1d1d1 51%,
        #fefefe 100%); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(top, #e2e2e2 0%, #dbdbdb 50%, #d1d1d1 51%, #fefefe
        100%); /* Opera 11.10+ */
    background: -ms-linear-gradient(top, #e2e2e2 0%, #dbdbdb 50%, #d1d1d1 51%, #fefefe
        100%); /* IE10+ */
    background: linear-gradient(to bottom, #e2e2e2 0%, #dbdbdb 50%, #d1d1d1 51%, #fefefe
        100%); /* W3C */
    filter: progid:DXImageTransform.Microsoft.gradient(              startColorstr='#e2e2e2',
        endColorstr='#fefefe', GradientType=0 ); /* IE6-9 */
}

.link:hover {
    background: rgb(230, 240, 163); /* Old browsers */
    background: -moz-linear-gradient(top, rgba(230, 240, 163, 1) 0%,
        rgba(210, 230, 56, 1) 50%, rgba(195, 216, 37, 1) 51%,
        rgba(219, 240, 67, 1) 100% ); /* FF3.6+ */
    background: -webkit-gradient(linear, left top, left bottom, color-stop(0%, rgba(230,
        240, 163, 1) ), color-stop(50%, rgba(210, 230, 56, 1) ),
        color-stop(51%, rgba(195, 216, 37, 1) ),
        color-stop(100%, rgba(219, 240, 67, 1) ) ); /* Chrome,Safari4+ */
    background: -webkit-linear-gradient(top, rgba(230, 240, 163, 1) 0%,
        rgba(210, 230, 56, 1) 50%, rgba(195, 216, 37, 1) 51%,
        rgba(219, 240, 67, 1) 100% ); /* Chrome10+,Safari5.1+ */
    background: -o-linear-gradient(top, rgba(230, 240, 163, 1) 0%,
        rgba(210, 230, 56, 1) 50%, rgba(195, 216, 37, 1) 51%,
        rgba(219, 240, 67, 1) 100% ); /* Opera 11.10+ */
    background: -ms-linear-gradient(top, rgba(230, 240, 163, 1) 0%,
        rgba(210, 230, 56, 1) 50%, rgba(195, 216, 37, 1) 51%,
        rgba(219, 240, 67, 1) 100% ); /* IE10+ */
    background: linear-gradient(to bottom, rgba(230, 240, 163, 1) 0%,
        rgba(210, 230, 56, 1) 50%, rgba(195, 216, 37, 1) 51%,
        rgba(219, 240, 67, 1) 100% ); /* W3C */
    filter: progid:DXImageTransform.Microsoft.gradient(                 
        startColorstr='#e6f0a3', endColorstr='#dbf043', GradientType=0 );
    /* IE6-9 */
}

table.linkTable {
    width: 100%;
}
4

1 回答 1

0

我认为这是不可能的,因为浏览器安全设置。

于 2013-06-17T11:41:07.683 回答