roscoeh23
asked on
opening a javascript link in php
This is what I have so far the syntax is wrong and I can't seem to get it. I want it to open 400px by 300px.
$strOut .= ' <a id="newsExtra'.$row['ID']. '" class="extra news" href="javascript:window.op en("news/r eadnews.ph p?ID='.$ro w['ID'].'" )" title="Read the full article with complete formatting" target="_blank"">Full Article</a>'."\n";
$strOut .= ' <a id="newsExtra'.$row['ID'].
sorry missed a double quote
$strOut .= ' <a id="newsExtra'.$row['ID']. '" class="extra news" href="javascript:window.op en(\'news/ readnews.p hp?ID="'.$ row['ID']. '"\')" title="Read the full article with complete formatting" target="_blank">Full Article</a>'."\n";
$strOut .= ' <a id="newsExtra'.$row['ID'].
ASKER
It does not work it just opens this..
javascript:window.open('ne ws/readnew s.php?ID=
it just cuts off where the php value should be
javascript:window.open('ne
it just cuts off where the php value should be
$strOut .= ' <a id="newsExtra'.$row['ID']. '" class="extra news" href="javascript:window.op en(\'news/ readnews.p hp?ID='.$r ow['ID'].' \')" title="Read the full article with complete formatting" target="_blank">Full Article</a>'."\n";
Defining height and width of the window
$strOut .= ' <a id="newsExtra'.$row['ID']. '" class="extra news" href="javascript:window.op en(\'news/ readnews.p hp?ID='.$r ow['ID'].' \',\'mywin dow\',\'wi dth=400,he ight=300\' )" title="Read the full article with complete formatting" target="_blank">Full Article</a>'."\n";
$strOut .= ' <a id="newsExtra'.$row['ID'].
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
$strOut .= ' <a id="newsExtra'.$row['ID'].