hanhao Posted June 4, 2006 Share Posted June 4, 2006 hi, i need to dymaically create a thumbnail button that when the user clicks on it, it does 2 things1. links to another page called (page1.php)2. popup another page in new browser called (page2.php) but set this popup in the backgroundbut the problem is <a href only allows 1 page to be linkedhow do i do the above?please help Link to comment https://forums.phpfreaks.com/topic/11141-dynamically-creating-a-image-that-links-to-2-other-urls/ Share on other sites More sharing options...
davidja Posted June 4, 2006 Share Posted June 4, 2006 this is more of a javascript question i would think. i'm looking in to it now.this doesn't use any PHP so you will have to work your php into it. i just want to get you the basic idea of how this could be done.here you go[code]<script>function popup( link , pop ){ window.open( pop ,null, "height=200,width=400,status=yes,toolbar=no,menubar=no,location=no"); document.location = link;}</script><body><img src="someimage" onclick="popup('http://www.phpfreaks.com','http://www.google.com')"></body>[/code] Link to comment https://forums.phpfreaks.com/topic/11141-dynamically-creating-a-image-that-links-to-2-other-urls/#findComment-41671 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.