我有一个充满缩略图的剑道列表视图。双击时,将调用一个 javascript 函数并打开一个 kendo ui 窗口。窗户开得很好;但是,图像不会显示在窗口中。
这是我到目前为止所尝试的:
function ShowImage(img) {
alert(img.src); //=== Image source is displayed correctly on the alert
var wimg = $("#imageWindow").data("kendoWindow");
wimg.open();
wimg.content("<img src='" + img.src + "' />");
//wimg.refresh(); //=== tried this but it didn't seem to make a difference.
}
我看不到任何错误。窗口只是空白。
谢谢您的帮助!
编辑:还尝试了变化:
function ShowImage(img) {
alert(img.src); //=== Image source is displayed correctly on the alert
var wimg = $("#imageWindow").data("kendoWindow");
wimg.content("<img src='" + img.src + "' />");
wimg.open();
}
也没有工作。