suma237 Posted August 18, 2007 Share Posted August 18, 2007 on selection of close option,can i open a new window ? <select> <option value="1" >Open</option> <option value="0" onClick="JavaScript:window.open('ajax2.php','view','height=350, width=550,scrollbars=1')">close</option> </select> Thanks in advance..Thanks Quote Link to comment https://forums.phpfreaks.com/topic/65553-solved-to-open-a-new-window/ Share on other sites More sharing options...
marcus Posted August 18, 2007 Share Posted August 18, 2007 Not much of a php question. <script language="Javascript"> function doThis(value){ if(value == "2"){ window.open('ajax2.php','view','height=350, width=550,scrollbars=1') } } </script> <form name="form"> <select name="option" onChange="doThis(this.value)"> <option value="1">Open</option><option value="2">Close</option> </select> </form> Quote Link to comment https://forums.phpfreaks.com/topic/65553-solved-to-open-a-new-window/#findComment-327323 Share on other sites More sharing options...
suma237 Posted August 18, 2007 Author Share Posted August 18, 2007 thanks ..i got it Quote Link to comment https://forums.phpfreaks.com/topic/65553-solved-to-open-a-new-window/#findComment-327324 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.