vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   ibProArcade Archive (https://vborg.vbsupport.ru/forumdisplay.php?f=174)
-   -   Saving issues (4.0.5) (https://vborg.vbsupport.ru/showthread.php?t=246713)

Jncocontrol 07-16-2010 04:23 PM

Saving issues (4.0.5)
 
My users are complaining about the their games not saving. I've tested it out and comfirmed that the games aren't saving.
Is their a Fix for this?

Hippy 07-25-2010 01:03 PM

did you add the edit to the index.php?
this is in the zip file of the arcade
Code:

If you are using vbAdvanced Portal and your /index.php is not the original one from vBulletin,
you have to edit your alternate index.php:

open index.php

At the very beginning of the File, right after:
----------------------------------------------------------
<?php
----------------------------------------------------------

you have to insert:
----------------------------------------------------------
// 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
----------------------------------------------------------


Otherwise your scores won't be recorded :)


2fast4ya 07-26-2010 09:02 PM

in the zip folder of the arcade there is index.html - are we sure its . php? or am i looking in the wrong place?

Hippy 07-26-2010 11:49 PM

you need to edit the index.php on your server ..

vb4 has a forum.php and a index.php
default

you'll find it in your root dir of the forum

AfterWorldForum 08-08-2010 01:05 PM

[S]
In the additional code posted, it refers to vBAdvanced.

I use that, as I find the vBCMS to be unfinished in so many ways I am of the opinion it never should have been released to begin with. Does the first line mean I should edit the vbAdvanced version of index.php, or should I instead put the addition in forums.php, which it points to?

Thanks in advance :)
[/S]

UPDATE: I just tried the index.php, and it seems to work. Now for the layout trouble :)

Hippy 08-17-2010 12:02 AM

I asume you fixed it ?

ellinofatsa 11-27-2010 12:17 PM

i have only index.php
and i have do that and the games dont safe the score and if i tab on the homepage i see this

Parse error: syntax error, unexpected T_DEC, expecting T_STRING or T_VARIABLE or '$' in C:\IIS_WEBSITES\ellinofatsa.www\index.php on line 58

Hippy 11-27-2010 12:24 PM

whats your url..


All times are GMT. The time now is 06:40 AM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01022 seconds
  • Memory Usage 1,729KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (1)bbcode_code_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (8)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete