Forum Moderators: open
$popup="<a href=\"javascript:void(0)\" onclick=\"window.open('index3.php,status=no,toolbar=no,scrollbars=yes,titlebar=no,menubar=no,resizable=yes,width=750,height=480,'); \" title=\"".$title."\">Link</a>";
If I echo $popup, the source code becomes:
<a href="javascript:void(0)" onclick="window.open(" index3.php,status="no,toolbar=no,scrollbars=yes,titlebar=no,menubar=no,resizable=yes,width=750,height=480,');'" title="The Title">Link</a>
It doesn't work. It won't popup. Can you please tell me what's wrong with my code?
Thanks.
onclick="window.open(" index3.php="" ,="" status="no,toolbar=no,scrollbars=yes,titlebar=no,menubar=no,resizable=yes,width=750,height=480');'" ...
Notice the singe quote became double. A single quote also placed right after the semi colon. Any ideas why this?
<a href="javascript:void(0)" onclick="window.open('index3.php','status=no,toolbar=no,scrollbars=yes,titlebar=no,menubar=no,resizable=yes,width=750,height=480');" title="..">Link</a>
I'm not sure why your single quotes would be transformed into double quotes.