简体   繁体   English

javascript弹出错误

[英]javascript pop-up error

I've an image column in an asp:repeater . 我在asp:repeater有一个图像列。

<asp:Image ID="telImage" runat="server" ImageUrl="../../images/telefon.png" />

I add onClick attribute in rptList_ItemDataBound 我在rptList_ItemDataBound添加onClick属性

telImage.Attributes.Add("onClick", "javascript: Redirect('" + telImage.ToolTip + "')");

and javascript method 和javascript方法

<script type="text/javascript">
    function Redirect(url) {
        if (confirm('Do you want to call?')) {
            window.open(url, "ekran", location = 1, status = 1, scrollbars = 1, width = 900, height = 700);               
        }
    }
</script>

When I click the image, a new window appears but it gives the following error: "HTTP Eror 404.0 - Not Found". 当我单击图像时,会出现一个新窗口,但会出现以下错误:“ HTTP Eror 404.0-Not Found”。 How can I solve this? 我该如何解决?

I only want to run that url address. 我只想运行该网址。 Is there any basic way? 有什么基本方法吗? I'm correctly taking the url address. 我正确地输入了网址地址。

The 3rd parameter of window.open must be string. window.open的第三个参数必须为字符串。 Try 尝试

'location = 1, status = 1, scrollbars = 1, width = 900, height = 700'

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

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