In a php script, at certain point I need to show up a GreyBox popup:
<?php
if ($myvar==''){
?>
<script>
// I need to show mypage.php in a GreyBox popup when in here
GB_showCenter('Title', 'mypage.php' , 300, 620);
</script>
<?php
}
?>
The code above shows the popup when $myvar is empty but mypage.php never loads, the loading gif never stops turning and Firebug shows a "GB null" error pointing to loader_frame.html.
I also tried:
GB_show("Title", "mypage.php");
but same problem.
If I do:
<a href="mypage.php" onclick="return GB_showCenter('Title', this.href , 300, 620)">Click here</a>
somewhere in the page I have the popup with no problems so I know the files are correctly installed.
What am I doing wrong?
Thanks a lot!
I know this is ugly, but can you try if it works:
OK - another one (even uglier):