I'm trying to open a link from a table row into a new window.
This is the code, which doesn't work.
Probably a simple answer, but I can't find it:
<TD WIDTH="180"><a href="javascript:void(0)" onClick="window.open('<?php echo no$match_no/scanned.php','guide', 'height=700, width=300, scrollbars=yes')"</a>; ?></TD>
Hope you can help.
Wayne.
New window with php variable
Moderator: General Moderators
Re: New window with php variable
One of the easiest ways to pass a variable to a new window is to put it into the url and grab it on the next page. This tutorial should help you understand that process better
http://www.w3schools.com/PHP/php_get.asp
hope that helps
http://www.w3schools.com/PHP/php_get.asp
hope that helps
Re: New window with php variable
I'm not sure exactly what you are trying to do, but maybe this?WayneG wrote:<TD WIDTH="180"><a href="javascript:void(0)" onClick="window.open('<?php echo no$match_no/scanned.php','guide', 'height=700, width=300, scrollbars=yes')"</a>; ?></TD>
Code: Select all
<td width="180"><a href="<?php echo $match; ?>" target="_blank"><?php echo $match; ?></a></td>