Lodius2000 Posted February 11, 2009 Share Posted February 11, 2009 I suck at js I got this from our own Darkerangel a few months ago, now I am trying to port it to a new website and the popup function is not working it is supposed to link to popup.html, that is in the same page as the page that is calling it here is the function and its call, with a little of the surrounding code </div><!-- hurry --> <div class="event"> <script type="text/javascript">\nfunction popupwindow() { new_window = window.open('popup.html','popup','width=501,height=351,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0'); } </script> <a href="javascript:popupwindow();"><h3>Event Details – Click Here</h3></a> </div><!-- event --> </div><!-- container --> //not sure if that '\' is supposed to be there in '\nfunction popupwindow()' but it does not work with or without it... thanks for the help Link to comment https://forums.phpfreaks.com/topic/144724-solved-popup-window-help/ Share on other sites More sharing options...
webster08 Posted February 11, 2009 Share Posted February 11, 2009 function popupwindow() { var new_window = window.open(document.location.href,'popup','width=501,height=351,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0'); } Link to comment https://forums.phpfreaks.com/topic/144724-solved-popup-window-help/#findComment-759425 Share on other sites More sharing options...
Lodius2000 Posted February 11, 2009 Author Share Posted February 11, 2009 im a moron, that code came form a php print statement so the fucntion definition line read 'slash-nfunction popup...' it had a \ and an n and I was too stupid to see that, works fine now... thanks Link to comment https://forums.phpfreaks.com/topic/144724-solved-popup-window-help/#findComment-759426 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.