MyBB Community Forums

Full Version: Error after installing reset game section scores.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
NEVERMIND - IT's BEEN FIXED

Quote:As the title says, is there any plugin like this?

I've got the score reset one which just resets one individual score, but If I remember ages ago, I could reset all scores with one button, can't remembe how I did it though.

Can anyone tell me?

Thanks.
That is fixed^

Also, after I installed it, I read the 'read me' file and replaced some code, now everythings all messed up for my game section:
http://prntscr.com/1uhiyv
^ There should be "Games" there.

And things has disapeared:
http://prntscr.com/1uhj3d
http://prntscr.com/1uhj70
http://prntscr.com/1uhj97

Can anyone fix this? Thanks.

This is what the 'read me' file was:
INSTALATION INSTRUCTIONS FOR THE GAME SECTION

1. UPLOAD THE FILES TO YOUR MYBB FORUM

2. OPEN ADMIN/MODULES/GAMES/GAMES.PHP AND FIND:
//Declare the sub-tabs
if($mybb->input['action'] == "" || $mybb->input['action'] == "add" || $mybb->input['action'] == "add_simple" || $mybb->input['action'] == "add_tar")
{
	$sub_tabs = array();
	$sub_tabs['overview'] = array(
		'title' => $lang->nav_overview,
		'link' => "index.php?module=games/games",
		'description' => $lang->nav_overview_desc
	);
	$sub_tabs['add_game'] = array(
		'title' => $lang->nav_add_game,
		'link' => "index.php?module=games/games&action=add",
		'description' => $lang->nav_add_game_desc
	);
	$sub_tabs['add_game_simple'] = array(
		'title' => $lang->nav_add_game_simple,
		'link' => "index.php?module=games/games&action=add_simple",
		'description' => $lang->nav_add_game_simple_desc
	);
	$sub_tabs['add_game_tar'] = array(
		'title' => $lang->nav_add_game_tar,
		'link' => "index.php?module=games/games&action=add_tar",
		'description' => $lang->nav_add_game_tar_desc
	);
}

REPLACE WITH:
//Declare the sub-tabs
if($mybb->input['action'] == "" || $mybb->input['action'] == "add" || $mybb->input['action'] == "add_simple" || $mybb->input['action'] == "add_tar")
{
	$sub_tabs = array();
	$sub_tabs['overview'] = array(
		'title' => $lang->nav_overview,
		'link' => "index.php?module=games/games",
		'description' => $lang->nav_overview_desc
	);
	$sub_tabs['add_game'] = array(
		'title' => $lang->nav_add_game,
		'link' => "index.php?module=games/games&action=add",
		'description' => $lang->nav_add_game_desc
	);
	$sub_tabs['add_game_simple'] = array(
		'title' => $lang->nav_add_game_simple,
		'link' => "index.php?module=games/games&action=add_simple",
		'description' => $lang->nav_add_game_simple_desc
	);
	$sub_tabs['add_game_tar'] = array(
		'title' => $lang->nav_add_game_tar,
		'link' => "index.php?module=games/games&action=add_tar",
		'description' => $lang->nav_add_game_tar_desc
	);
	$sub_tabs['reset_scores'] = array(
		'title' => $lang->reset_scores,
		'link' => "index.php?module=games/games&action=reset_scores&gid=all&my_post_key=".$mybb->post_code."\" onclick=\"return AdminCP.deleteConfirmation(this, '".$lang->reset_scores_confirmation."')"
	);
}

3. IN THE SAME FILE, FIND:
		$table->construct_cell("<a href=\"index.php?module=games/games&amp;action=edit&amp;gid=".$games['gid']."\">".$lang->edit_game."</a><br />
<a href=\"index.php?module=games/games&amp;action=delete&amp;gid=".$games['gid']."&amp;my_post_key=".$mybb->post_code."\">".$lang->delete_game."</a><br />
".$category_edit."
<a href=\"index.php?module=games/gamedata&amp;directory=".$games['name']."\">".$lang->gamedata."</a><br /><br />
<a href=\"../games.php?action=play&amp;gid=".$games['gid']."\">".$lang->play_game."</a>", array("width" => 125));

REPLACE WITH:
		$table->construct_cell("<a href=\"index.php?module=games/games&amp;action=edit&amp;gid=".$games['gid']."\">".$lang->edit_game."</a><br />
<a href=\"index.php?module=games/games&amp;action=delete&amp;gid=".$games['gid']."&amp;my_post_key=".$mybb->post_code."\">".$lang->delete_game."</a><br />
".$category_edit."
<a href=\"index.php?module=games/gamedata&amp;directory=".$games['name']."\">".$lang->gamedata."</a><br />
<a href=\"index.php?module=games/games&amp;action=reset_scores&amp;gid=".$games['gid']."&amp;my_post_key=".$mybb->post_code."\" onclick=\"return AdminCP.deleteConfirmation(this, '".$lang->reset_scores_confirmation."')\">".$lang->reset_scores."</a><br /><br />
<a href=\"../games.php?action=play&amp;gid=".$games['gid']."\">".$lang->play_game."</a>", array("width" => 125));

4. ACTIVATE THE PLUGIN
No-one help?
..................