0
如果您在jquery中調用模態對話框,但圖像文件位於數組中,那麼如何調用此對話框,如果點擊鏈接,圖像會彈出?現在,由於一個循環,它顯然只使用最後一個文件名。jquery和Coldfusion循環
function showDialog(){
$("#image_viewer").html('<iframe id="modalIframeId" width="100%" height="100%" marginWidth="0" marginHeight="0" frameBorder="0" scrolling="auto" />').dialog("open");
$("#modalIframeId").attr("src","image_view.cfm");
return false;
}
$(document).ready(function() {
$("#image_viewer").dialog({
autoOpen: false,
modal: true,
height: 800,
width: 600
});
});
你可以發佈你的CF代碼嗎?不太清楚你想從JavaScript中做什麼。 – bpanulla 2011-05-03 20:17:39
從你的問題,很難說出你有什麼問題。此外,您提到了循環,但是您發佈的代碼中沒有循環。你能否提供一些額外的代碼,和/或澄清你的問題? – Ender 2011-05-03 20:29:39