새창 띄우기 스크립트

2012. 8. 26. 17:41교육

새창 띄우기 스크립트 




새창 띄우기 <a href="javascript:void(window.open('주소','팝업이름','width=가로,height=세로'))">Link</a> 



온클릭 이용 <a href="#" onClick="window.open('주소','팝업이름','width=가로,height=세로');return false">Link</a> 


버튼을 클릭할때 새창 띄우기 <input type="button" value="JSGUIDE" onClick="window.open'주소','팝업이름','width=가로,height=세로')">


페이지 로딩이 완료되면 새창 띄우기 <BODY onLoad="window.open('주소','팝업이름','width=가로,height=세로')">


무조건 새창 띄우기  <script langauge="javascript"> window.open("주소","팝업이름","width=가로,height=세로"); </script>


몇초 후에 새창 띄우기 <script langauge="javascript"> setTimeout("window.open('주소','팝업이름','width=가로,height=세로')",5000); //1000 = 1초 </script>



설정


location=no,directories=no,resizable=no,status=no,toolbar=no,menubar=no, 

width=300,height=400,left=0,top=0,scrollbars=yes