Log in

View Full Version : renaming my index.php


VaaKo
12-13-2005, 06:31 PM
I just installed vbadvanced CMPS, and I would like to rename my index.php (forum) into forum.php so I can rename my CMPS file index.php
so that when users enter my site they get the portal first and then they click on the forum.php

NOT: that the portal and the forum are on the same dir

TyleR
12-13-2005, 06:35 PM
just rename it, then go to AdminCP->vBulletin Options->Forum Home Page Options-> Set the first box to forum instead of index.

VaaKo
12-14-2005, 04:49 AM
it worked but now my arcade is messed up, everytime a user tries to save his highscore, it redirects him to the portal
I donno why
so I restore it

any other way to make people enter portal.php instead of index.php?

Brandon Sheley
12-14-2005, 05:04 AM
make an index.html file, put it in your root. and place this in it

<html>
<head>
<title>your site name.... </title>
<script language="JavaScript">
self.location.href='/forums/portal.php';
</script>
</head>
<body>
</body>
</html>

;)

VaaKo
12-14-2005, 12:15 PM
that didn't work :\
weird :\

any other way?

maybe htaccess file?
could that work?

utw-Mephisto
12-14-2005, 01:01 PM
In your index.php (which ever) add this at the top of the file just below <?php


if($_POST['module'] == "pnFlashGames"){
$_GET[act] = "Arcade";
$_GET['module'] = "arcade";
}
if($_POST['func'] == "storeScore"){
$_GET['do'] = "pnFStoreScore";
}
if($_POST['func'] == "saveGame"){
$_GET['do'] = "pnFSaveGame";
}
if($_POST['func'] == "loadGame"){
$_GET['do'] = "pnFLoadGame";
}
$act = $_GET[act];
$showuser= $_GET[showuser];
if($act == "Arcade") {
include "arcade.php";
exit();
}
if(!empty($showuser) && $showuser >= 1) {
$u = $showuser;
$_GET[u] = $showuser;
include "member.php";
exit();
}


Arcade should be able now to save the highscore correctly ... I am using also forum.php instead of index.php because my cms needs an index.php (also vbadvanced)

Oh, assuming you use ibproarcade as on ut2007world.com

So your index.php should look like


<?php
// ++================================================ =========================++
// || vBadvanced CMPS v2.0.0 (vB 3.5) - 9656
// || ? 2003-2004 vBadvanced.com & PlurPlanet, LLC - All Rights Reserved
// || This file may not be redistributed in whole or significant part.
// || http://vbadvanced.com
// || Downloaded 03:54, Fri Dec 9th 2005
// ||
// ++ ================================================== ======================++


// ibproarcade modification
if($_POST['module'] == "pnFlashGames"){
$_GET[act] = "Arcade";
$_GET['module'] = "arcade";
}
if($_POST['func'] == "storeScore"){
$_GET['do'] = "pnFStoreScore";
}
if($_POST['func'] == "saveGame"){
$_GET['do'] = "pnFSaveGame";
}
if($_POST['func'] == "loadGame"){
$_GET['do'] = "pnFLoadGame";
}
$act = $_GET[act];
$showuser= $_GET[showuser];
if($act == "Arcade") {
include "arcade.php";
exit();
}
if(!empty($showuser) && $showuser >= 1) {
$u = $showuser;
$_GET[u] = $showuser;
include "member.php";
exit();
}
// end of ibproarcade modification

error_reporting(E_ALL & ~E_NOTICE);
define('NO_REGISTER_GLOBALS', 1);
define('THIS_SCRIPT', 'adv_index');
define('VBA_PORTAL', true);
define('VBA_SCRIPT', 'CMPS');

// ============================================
// Enter the full path to your forum here
// Example: /home/vbadvanced/public_html/forum
// ============================================

chdir('/xxxxxx);

// ============================================
// No Further Editing Necessary!
// ============================================

$phrasegroups = array();
$globaltemplates = array();
$actiontemplates = array();
$specialtemplates = array();

require_once('./global.php');

print_portal_output($home);

?>

VaaKo
12-14-2005, 03:42 PM
thx man, seems to be working fine
really thx

utw-Mephisto
12-14-2005, 03:57 PM
glad that it worked ;)

KW802
12-14-2005, 05:44 PM
utw-Mephisto,

Please remove vBa file quoted above.

Thanks