document。write("")內可以寫div樣式嗎?
如下面那樣,如果需要怎么才能實現效果。
document.write("Hello"+"<div style="width:50px;height:50px;background-color:red;">world</div>");
如下面那樣,如果需要怎么才能實現效果。
document.write("Hello"+"<div style="width:50px;height:50px;background-color:red;">world</div>");
2016-11-09
舉報
2017-01-17
為什么引用document.write("Hello"+"<div style="width:50px;height:50px;background-color:red;">world</div>"); ?實現不了?
2016-11-09
document.write()中可以嵌入標簽,在標簽中寫css樣式,這樣挺方便的.
2016-11-09
可以??? 要注意? 引號之間的轉義
2016-11-09
可以啊,只是有些麻煩