mikeh623 Posted May 12, 2006 Share Posted May 12, 2006 I have a popup window named 'admin.' It launches another popup with several links. Those links have src and target attributes, their target is the admin window. They also have an onClick attribute of "self.close()" so that the window will close when the link is pressed.In Internet Explorer this works perfectly, the link is clicked, direction is sent to 'admin' and then it closes and admin takes over from there.In FireFox this does not work at all as planned. You click the link and the window closes without sending direction to admin. Please assist. Thanks! Quote Link to comment https://forums.phpfreaks.com/topic/9551-popup-closes-but-doesnt-send-to-target/ Share on other sites More sharing options...
GBS Posted May 17, 2006 Share Posted May 17, 2006 Hi,,Maybe if you post some code lines about your popup function, we could test it & help more,,...In my first opinion, your problem could be about the 'src' attribute...Because I've tested that firefox doesn't like when you change some elements attributes (like onclick, onchange, etc...)So, you should try using the setAttribute / getAttribute methods,...Hoping it helps,,l8tr,, Quote Link to comment https://forums.phpfreaks.com/topic/9551-popup-closes-but-doesnt-send-to-target/#findComment-36704 Share on other sites More sharing options...
mikeh623 Posted May 18, 2006 Author Share Posted May 18, 2006 The link code:[code]<a href=\"admin_ops.php?op=addClan&pid={$pid}&cid={$clan}&lid={$lads['ladderid']} &clan={$clan_name}\" target=\"admin\" onClick=\"self.close();\">Add to Clan</a>[/code]The function code used to open the window that the above link is in:[code]<script language=\"javascript\" type=\"text/javascript\"> popup_win = null; function newwin() { popup_win = window.open('clanAddition.php','clanAddition','width=300,height=250,toolbar=no,location=no,\ directories=no,status=no,menubar=no,scrollbars=no,copyhistory=no,resizable=no'); } </script>[/code]The function code used to open the 'admin' window which direction should be sent to:[code]<script language=\"javascript\" type=\"text/javascript\"> function admin() { window.open('admin/index.php','admin','width=800,height=516,toolbar=no,location=no,directories=no,status=no,menubar=no,scrollbars=no,copyhistory=no,resizable=no'); } </script>[/code]When you click the top link, the window should close and direction sent to the admin window, the parent window of the window containing the link. This works fine in Internet Explorer, but in Firefox, the window closes and nothing more happens.Note: The ' above is not in my code, for some reason it is showing up in the post.Thanks. Quote Link to comment https://forums.phpfreaks.com/topic/9551-popup-closes-but-doesnt-send-to-target/#findComment-36884 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.