Fatal error: Call t...
 
Notifications
Clear all

Fatal error: Call to undefined function dbquery() in upgrade20.php

32 Posts
4 Users
0 Reactions
18.6 K Views
(@marauder-by-midnight)
Posts: 56
Trusted Member
Topic starter
 

Thanks πŸ™‚ But now, I can't even open install.php because I was trying to keep people from seeing it on the main page.

How do you continue the install without letting others see it?


 
Posted : 16/03/2008 12:35 pm
 Elle
(@jenny)
Posts: 594
Honorable Member
 

I don't think you can.

You could try password protecting the entire subdomain, though it may be extreme.

I've just thought of something, though, the config's changed so the script might no longer think it's a 2.x install. OK! Delete that and include the dbfunctions in the upgrade20.php and see what happens. 😐

include ("../includes/class.TemplatePower.inc.php");
include("../config.php");
include_once("../includes/dbfunctions.php");

if(isset($_GET['step']) && $_GET['step'] > 2) {
$settings = dbquery("SELECT tableprefix, language FROM ".$settingsprefix."fanfiction_settings WHERE sitekey = '".$sitekey."'");
list($tableprefix, $language) = dbrow($settings);


archive: dramione.org
site: accio.nu

Available for skin/mod commission! πŸ™‚

 
Posted : 16/03/2008 12:40 pm
(@marauder-by-midnight)
Posts: 56
Trusted Member
Topic starter
 

Now I'm getting this error:

Warning: mysqli_query() expects parameter 1 to be mysqli, null given in /home/fanfiction/public_html/includes/mysqli_functions.php on line 19

Warning: mysqli_errno() expects parameter 1 to be mysqli, null given in /home/fanfiction/public_html/includes/mysqli_functions.php on line 19

Warning: mysqli_error() expects parameter 1 to be mysqli, null given in /home/fanfiction/public_html/includes/mysqli_functions.php on line 19
_FATALERRORQuery: SELECT tableprefix, language FROM fanfiction_settings WHERE sitekey = ''
Error: ()

Line 19 in msqli_functions.php:

$result = mysqli_query($dbconnect, $query) or die( _FATALERROR."Query: ".$query."<br />Error: (".mysqli_errno( $dbconnect ).") ".mysqli_error( $dbconnect ));


 
Posted : 16/03/2008 12:49 pm
 Elle
(@jenny)
Posts: 594
Honorable Member
 

Disregarding that error for a moment (for that I can only a hazard a guess at a missing table prefix or sitekey...), is the error on index.php intentional to stop people from seeing the site?


archive: dramione.org
site: accio.nu

Available for skin/mod commission! πŸ™‚

 
Posted : 16/03/2008 12:56 pm
(@marauder-by-midnight)
Posts: 56
Trusted Member
Topic starter
 

Yes. This is what I have in index.php at the moment:

<?php

echo = 'Site under construction' ;

?>


 
Posted : 16/03/2008 1:01 pm
 Elle
(@jenny)
Posts: 594
Honorable Member
 

The = sign isn't needed.

Have you got a page with the original index.php's contents? :3


archive: dramione.org
site: accio.nu

Available for skin/mod commission! πŸ™‚

 
Posted : 16/03/2008 1:05 pm
(@marauder-by-midnight)
Posts: 56
Trusted Member
Topic starter
 

Yes I do. Do you need that to fix the error?


 
Posted : 16/03/2008 1:07 pm
 Elle
(@jenny)
Posts: 594
Honorable Member
 

What does it say/output now? :3


archive: dramione.org
site: accio.nu

Available for skin/mod commission! πŸ™‚

 
Posted : 16/03/2008 1:16 pm
(@marauder-by-midnight)
Posts: 56
Trusted Member
Topic starter
 

"BOO I AM A DEMENTOR. Go away now."

Does it have something to do with the error I'm getting when I upgrade though? Is it causing the error?


 
Posted : 16/03/2008 1:18 pm
 Elle
(@jenny)
Posts: 594
Honorable Member
 

No, but it might help debug it, which is what I'm heading for.

You modified the index.php, so it won't give any comments. Um, do you have the original index.php on file, you rename or save it to your computer?

It's this:

$current = "home";

include ("header.php");

//make a new TemplatePower object

if(file_exists("$skindir/index.tpl")) $tpl = new TemplatePower( "$skindir/index.tpl" );
else $tpl = new TemplatePower("default_tpls/index.tpl");
//let TemplatePower do its thing, parsing etc.

include("includes/pagesetup.php");
$query = dbquery("SELECT message_text FROM ".TABLEPREFIX."fanfiction_messages WHERE message_name = 'welcome'");
list($welcome) = dbrow($query);
$tpl->assign("welcome", stripslashes($welcome));

$tpl->printToScreen();
dbclose( );

All that's after the license/notes commented section.


archive: dramione.org
site: accio.nu

Available for skin/mod commission! πŸ™‚

 
Posted : 16/03/2008 1:29 pm
(@marauder-by-midnight)
Posts: 56
Trusted Member
Topic starter
 

Saved it to my computer.

I have:

$current = "index";

include ("header.php");

//make a new TemplatePower object

if(file_exists("$skindir/index.tpl")) $tpl = new TemplatePower( "$skindir/index.tpl" );
else $tpl = new TemplatePower("default_tpls/index.tpl");
$tpl->assignInclude( "header", "./$skindir/header.tpl" );
$tpl->assignInclude( "footer", "./$skindir/footer.tpl" );

//let TemplatePower do its thing, parsing etc.
$tpl->prepare();

include("func.pagemenu.php");
$tpl->assign("welcome", file_get_contents("messages/welcome.php"));

$tpl->printToScreen();
?>


 
Posted : 16/03/2008 1:31 pm
 Elle
(@jenny)
Posts: 594
Honorable Member
 

Upload the old index.php; replacing the current. If we can see the errors that has, I can try and see what happens and/or see the debug info. To divert visitors change the current index.php to index.html which'll be the first index they see when they go to it.


archive: dramione.org
site: accio.nu

Available for skin/mod commission! πŸ™‚

 
Posted : 16/03/2008 1:33 pm
(@marauder-by-midnight)
Posts: 56
Trusted Member
Topic starter
 

I get:

Warning: mysqli_query() expects parameter 1 to be mysqli, null given in /home/fanfiction/public_html/includes/mysqli_functions.php on line 19

Warning: mysqli_errno() expects parameter 1 to be mysqli, null given in /home/fanfiction/public_html/includes/mysqli_functions.php on line 19

Warning: mysqli_error() expects parameter 1 to be mysqli, null given in /home/fanfiction/public_html/includes/mysqli_functions.php on line 19
_FATALERRORQuery: SELECT tableprefix, language FROM fanfiction_settings WHERE sitekey = ''
Error: ()

In the middle of step 10 (updating stories and series)


 
Posted : 16/03/2008 1:36 pm
 Elle
(@jenny)
Posts: 594
Honorable Member
 

Do you have MSN or something? :3


archive: dramione.org
site: accio.nu

Available for skin/mod commission! πŸ™‚

 
Posted : 16/03/2008 1:39 pm
(@marauder-by-midnight)
Posts: 56
Trusted Member
Topic starter
 

I was going to ask you the same thing xD

I have AIM.


 
Posted : 16/03/2008 1:41 pm
Page 2 / 3
Share: