Есть ли способ загрузить CSS во время всплывающего окна?window.open load load CSS
function kmt_ShowBoxPopup(targetDivID, aTag)
{
var orgin_div_content=document.getElementById(targetDivID).innerHTML;
//alert(targetDivID);
showBoxPopupWin =window.open("",targetDivID,'height=400,width=710,screenX=250,screenY=80, scrollbars=yes');
showBoxPopupWin.document.write ('<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN""http://www.w3.org/TR/html4/strict.dtd">'+
'<html><head><title>'+targetDivID+'</title></head><body>'+orgin_div_content+'</body</html>');
if (window.focus) {showBoxPopupWin.focus()}
}
<a class="cs_popuplink" onclick="kmt_ShowBoxPopup('BOX02_01',this); return false; ">show me how..</a>
<div id = "BOX02_01" STYLE=display:none>
p
p
p
</div>
Вот мой код. Я хотел бы загрузить CSS в функцию showBoxPopupwin.document.write. Является ли это возможным?
веселит, Цин
Спасибо, следующий вопрос, я также могу загрузить javascript. Правильно? – QLiu
Это HTML-документ. Вы можете делать все, что можете, в обычном HTML-документе. –