1 개요[ | ]
- Dynamically create iframe with jQuery
- jQuery iframe 생성
html
Copy
<style>
.myFrame {
background-color: red;
float: right;
clear: both;
}
</style>
<script src="//code.jquery.com/jquery.min.js"></script>
<script>
$(function() {
$('#create_frame').click(function() {
var new_frame = $('<iframe class="myFrame"></iframe>');
new_frame.appendTo('body');
});
});
</script>
<button id='create_frame'>프레임 생성</button>
2 같이 보기[ | ]
3 참고[ | ]
편집자 Jmnote Jmnote bot
로그인하시면 댓글을 쓸 수 있습니다.