Quote:
Originally Posted by docvader
Score not saving: Missing token..
Me too, after upgrade to 2.71. tried adding the code to index.php as you suggested in post one, get this error:
Parse error: syntax error, unexpected T_DEC, expecting T_STRING or T_VARIABLE or '$' in /home/username/public_html/forum/index.php on line 2
I'm not too keen on renaming forum to index and vice versa, etc, not because I can't do it, but because I'll completely forget about this once vbulletin gets upgraded, which seems to be fairly frequently, not to mention the google site searching changes. Any other fix for this? In a way that can keep this whole process functional and simple?
|
right after
<?php
add the code
so the top of your index.php file will look like this
Code:
<?php
// 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_INT);
$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
the the rest of the index code will be under // end of ibProArcade
hope this helps ..
you can pm me if you get stuck..
will help you out
I am off to bed tho ATM so it will be tomorrow
enjoy
Quote:
Originally Posted by jaffaman
Thanks alot 
|
welcome
glad to help