1

I am looking to open a aspx page to act an an image uploader.. this is the code I use to open the page:

$("#btnUpload").on("click", function (s) {
    s.preventDefault();
    var id = $('#hdnId').val();
    var response = window.showModalDialog("/imageUpload.aspx/", id);
    alert(response);
});

the page opens fine and looks like this:

<head runat="server">
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
        <div>
            <label>Choose New Image:</label>
            <br/>

            <asp:FileUpload ID="imageUploader" runat="server"></asp:FileUpload>

            <asp:Button id="UploadButton" OnClick="UploadButton_Click" Text="Upload file" runat="server"></asp:Button>     
        </div>
    </form>
</body>
</html>

The fileupload renders ok on the page - but the choose file button doesn't work at all! ive watched in chrome & there are no jquery errors on page load or on click of the choose file button.

I've done a bit of googling and found that ajax and update panels are dodge with the fileuploader - But i'm not using either :-/

anyone know whats occurring here?? many thanks

4

1 回答 1

0

我在 Chrome 模态对话框中遇到了同样的问题。这是一个 Chrome v26 问题。您可以查看以下 url 以了解 chrome 错误跟踪器的详细信息。

https://code.google.com/p/chromium/issues/detail?id=225365

然而,他们已经修复了该缺陷,但据他们称,将修复包含到发布中需要长达 6 周的时间。您可以获取 Chrome 金丝雀版本进行验证。

https://www.google.com/intl/en/chrome/browser/canary.html

于 2013-05-17T09:05:46.737 回答