aacircle
08-22-2007, 02:27 PM
Hello,
As per the title of this thread, my forum's main page is not index.php. It is forum.php. Do I go an edit this file with the following:
// ibProArcade
if($_POST[module] == "pnFlashGames")
{
require_once("./global.php");
switch($_POST[func])
{
case "storeScore":
$_GET[act] = "Arcade";
$_GET[module] = "arcade";
$_GET[do] = "pnFStoreScore";
break;
case "saveGame":
$_GET[do] = "pnFSaveGame";
break;
case "loadGame":
$_GET[do] = "pnFLoadGame";
break;
case "loadGameScores":
$gid = $vbulletin->input->clean_gpc("p", "gid", TYPE_NOHTML);
$uid= $vbulletin->userinfo[userid];
$game = $db->query_first("SELECT * FROM " . TABLE_PREFIX . "games_scores WHERE mid=$uid AND gid = $gid ORDER BY score DESC LIMIT 0,1");
$scores = $game[score];
if($scores != false)
{
//Return true
print "&opSuccess=true&gameScores=$scores&endvar=1"; //send endvar to keep opSuccess separate from all other output from PostNuke
}
else
{
print "&opSuccess=false&error=Error&endvar=1";
}
break;
}
}
$act = $_GET[act];
$autocom = $_GET[autocom];
$showuser= $_GET[showuser];
if($act == "Arcade" || $autocom=="arcade") {
include "arcade.php";
exit();
}
if(!empty($showuser) && $showuser >= 1) {
$u = $showuser;
$_GET[u] = $showuser;
include "member.php";
exit();
}
// end of ibProArcade
I have tried this, but get the following error when viewing my forum.php file:
Parse error: parse error, unexpected T_DO, expecting ']' in /home/mydomain/public_html/forum.php on line 12
I've looked at the above code, and all brackets are indeed closed.
Is the above a mandatory step? All my scores are recorded correctly.
Thank you.
As per the title of this thread, my forum's main page is not index.php. It is forum.php. Do I go an edit this file with the following:
// ibProArcade
if($_POST[module] == "pnFlashGames")
{
require_once("./global.php");
switch($_POST[func])
{
case "storeScore":
$_GET[act] = "Arcade";
$_GET[module] = "arcade";
$_GET[do] = "pnFStoreScore";
break;
case "saveGame":
$_GET[do] = "pnFSaveGame";
break;
case "loadGame":
$_GET[do] = "pnFLoadGame";
break;
case "loadGameScores":
$gid = $vbulletin->input->clean_gpc("p", "gid", TYPE_NOHTML);
$uid= $vbulletin->userinfo[userid];
$game = $db->query_first("SELECT * FROM " . TABLE_PREFIX . "games_scores WHERE mid=$uid AND gid = $gid ORDER BY score DESC LIMIT 0,1");
$scores = $game[score];
if($scores != false)
{
//Return true
print "&opSuccess=true&gameScores=$scores&endvar=1"; //send endvar to keep opSuccess separate from all other output from PostNuke
}
else
{
print "&opSuccess=false&error=Error&endvar=1";
}
break;
}
}
$act = $_GET[act];
$autocom = $_GET[autocom];
$showuser= $_GET[showuser];
if($act == "Arcade" || $autocom=="arcade") {
include "arcade.php";
exit();
}
if(!empty($showuser) && $showuser >= 1) {
$u = $showuser;
$_GET[u] = $showuser;
include "member.php";
exit();
}
// end of ibProArcade
I have tried this, but get the following error when viewing my forum.php file:
Parse error: parse error, unexpected T_DO, expecting ']' in /home/mydomain/public_html/forum.php on line 12
I've looked at the above code, and all brackets are indeed closed.
Is the above a mandatory step? All my scores are recorded correctly.
Thank you.