hjpotter92
The Boy Who Lived
On my page, the following function has been created:
And, the page itself is modList.php which loads data of different game-mods from SQL table. I want each of the game-mod name clickable, so that a pop-up opens. I am using this in the php page generation:
Upto this, no trouble is faced. Now, the trouble is pop-up window opens for the first entry in the table, but not for any of the other 516 values.
I thought of having another file to process the mod name( for eg. modData.php ) but, the problem is still there.
Please help. If anything is missing there, please mention, and I will try to put it up too!
EDIT
Ignore the question. Problem was solved. Seems like I must've used this
Code:
<SCRIPT language="javascript" type="text/javascript">
function popModData( modName )
{
var url = "./modList.php?mod=" + modName;
newWindow = window.open( url, modName, 'width=500,height=500,scrollbars=no,resizable=no,toolbar=no,directories=no,location=no,menubar=no,status=no,left=0,top=0');
if( window.focus ) { newWindow.focus() }
return false;
}
</SCRIPT>
And, the page itself is modList.php which loads data of different game-mods from SQL table. I want each of the game-mod name clickable, so that a pop-up opens. I am using this in the php page generation:
PHP:
while( $modTable = mysql_fetch_array( $getMod ) )
{
$colour = ( $i % 2 )? "#99EECC" : "CCDDFF";
echo "\t\t\t<tr bgcolor='$colour'>";
echo "\n\t\t\t\t<td>" . $i++ . ".</td>";
echo "\n\t\t\t\t<td onclick='return popModData($modTable[Name]);'>$modTable[Name]</td>";
echo "\n\t\t\t\t<td>$modTable[From]</td>\n\t\t\t</tr>";
}
I thought of having another file to process the mod name( for eg. modData.php ) but, the problem is still there.
Please help. If anything is missing there, please mention, and I will try to put it up too!
EDIT
Ignore the question. Problem was solved. Seems like I must've used this
PHP:
echo "\n\t\t\t\t<td onclick='return popModData(\"$modTable[Name]\");'>$modTable[Name]</td>";