使用javascript:openwindow打开pdf文件时出现“访问被拒绝"错误 [英] 'Access Denied' Error when open pdf file using javascript:openwindow
本文介绍了使用javascript:openwindow打开pdf文件时出现“访问被拒绝"错误的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
当我尝试使用javascript打开窗口打开pdf文件时,出现访问被拒绝"错误.
我已经提到了这条路.但是,pdf页面没有出现,并且还会出现访问被拒绝"错误.
参见代码和路径
------------------
I am getting ''Access Denied'' Error when i am trying to open pdf file using javascript open window.
I have mentioned the path already. But, the pdf page is not coming and also getting ''Access Denied'' Error.
see code and path
------------------
function openwindow(url,title)
{
var MovWin = window.open(url, 'Newwindow','fullscreen=no,location=no,directories=no,toolbar=no,menubar=no,left=0,top=0,height=700,width=1020,scrollbars=yes,resizable=yes');
MovWin.document.title = title;
}
<tr>
<td width="50%" valign="top" align="left"> 2.1
<a style="text-decoration: none; color: #000080;" title="text" href="java<!-- no -->script: void(0)">
onmouseover="this.style.fontWeight=''bold''" onmouseout="this.style.fontWeight=''normal''"
önclick="javascript:openwindow(''C:\\ABA\ABC1\Pro\APPLICATION\USA\Documents\GENERAL EMPLIST.pdf'',''New Window'')">Policy</a></td>
</tr>
推荐答案
以这种方式使用网址!
use the url this way!!!!!
var url="C:/\Documents and Settings/\sanjeev.a/\Desktop/\practicingApp/\Visual-Studio-vNext-Preview-Web[1].pdf";
这篇关于使用javascript:openwindow打开pdf文件时出现“访问被拒绝"错误的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文