Seite 1 von 2

statistic-Mod (SQL-Fehler)

Verfasst: 30.03.2003 15:39
von pinki78
Hab heute das Stat-Mod installiert, bekomme folgende Fehlermeldung !!!
Could not query statistics config table

DEBUG MODE

SQL Error : 1146 Table 'toyotas_xmb1.STATS_CONFIG_TABLE' doesn't exist

SELECT * FROM STATS_CONFIG_TABLE

Line : 36
File : /home/toyotas/public_html/forum/statistics.php
die Zeile 31 - 39 in der statistix.php sieht so aus
$sql = 'SELECT *
FROM ' . STATS_CONFIG_TABLE;

if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not query statistics config table', '', __LINE__, __FILE__, $sql);
}

while ($row = $db->sql_fetchrow($result))
ich weiß, ja selber das da irgendwas mit dem SQL nicht stimmt, aber was ?
Bin da noch Anfänger

Muß man die "STATS_CONFIG_TABLE" manuell anlegen ????
ich denke doch nicht oder ?

Achso hab nur folgendes installiert:


Nach Anleitung die Datei hochgeladen

includes/constants.php modifiziert
templates/subSilver/overall_header.tpl modifiziert

---------------------------------------

das hier verstehe ich auch nicht, in der Anleitung steht dies
NOTE: THIS STEP IS ONLY NEEDED IF YOU USE THE FILE-BASED CACHED TEMPLATE.PHP FILE
#
# If you are using the template cache system (only file-based is mentioned here),
# please adjust your template.php as followed (This will NOT disable the Template Caching)
# It is a little tweak to let the template use the non-cached output if no cached template
# file could be found.
#-------------------------------------------------------------

#
#-----[ OPEN ]---------------------------------------------
#
includes/template.php

#
#-----[ FIND ]---------------------------------------------
# around line 144
$fp = fopen($cache_file, 'w+');
fwrite ($fp, '<?php' . "\n" . $this->compiled_code[$handle] . "\n?" . '>');

die Zeile mit dem Code ist bei mir garnicht existent ?!?!

am besten ihr guckt euch das selber ma an

http://www.toyotas-bb.de/forum/index.php

Verfasst: 30.03.2003 16:22
von saerdnaer
es sieht so aus als hättest du die constants.php falsch bzw. garnicht hochgeladen...

lad die datei nochmal in der includes ordner und zwar im text oder ascii modus...

zu dem
NOTE: THIS STEP IS ONLY NEEDED IF YOU USE THE FILE-BASED CACHED TEMPLATE.PHP FILE
das soll heißen das du diese änderungen nur machen musst wenn du das datei basierende template cacheing system benutzt... und wenn du die zeile nicht findest benutzt du es auch nicht...

ah

Verfasst: 30.03.2003 16:48
von pinki78
geht immer noch nicht, hab die Datei nochmal komplett modifiziert und im Ascii hochgeladen

so sieht die Mod aus

Zeile 23-28
if ( !defined('IN_PHPBB') )
{
die("Hacking attempt");define('MODULES_TABLE', $table_prefix . 'stats_modules');
define('STATS_CONFIG_TABLE', $table_prefix . 'stats_config');

}

hab zwar zwei SQL -Tabellen die was mit Stats zu tun haben aber irgendwie heißt die wohl anders

Home
(Datenbanken) ... toyotas_xmb1 (30)

--------------------------------------------------------------------------------
toyotas_xmb1
phpbb_auth_access
phpbb_banlist
phpbb_categories
phpbb_config
phpbb_disallow
phpbb_forum_prune
phpbb_forums
phpbb_groups
phpbb_posts
phpbb_posts_text
phpbb_privmsgs
phpbb_privmsgs_text
phpbb_ranks
phpbb_search_results
phpbb_search_wordlist
phpbb_search_wordmatch
phpbb_sessions
phpbb_smilies
phpbb_stats_config ? Ist es die hier ?
phpbb_stats_modules
phpbb_themes
phpbb_themes_name
phpbb_topics
phpbb_topics_watch
phpbb_user_group
phpbb_users
phpbb_vote_desc
phpbb_vote_results
phpbb_vote_voters
phpbb_words

--------------------------------------------------------------------------------
ich versteh es nicht !!!

Moment, mal !
die Tabelle heißt "phpbb_stats_config" und nicht "phpbb_stats_config_table" liegt es daran ?

Verfasst: 30.03.2003 16:51
von saerdnaer
aber ich ... zeig mal die einbau anweisungen für constans.php

und probiers mal so:

Code: Alles auswählen

if ( !defined('IN_PHPBB') ) 
{ 
die("Hacking attempt");
}

define('MODULES_TABLE', $table_prefix . 'stats_modules'); 
define('STATS_CONFIG_TABLE', $table_prefix . 'stats_config'); 
0
ah

Verfasst: 30.03.2003 16:59
von pinki78
Einbauanweisung
#-----[ OPEN ]------------------------------------------
#
includes/constants.php

#
#-----[ FIND ]------------------------------------------
#
if ( !defined('IN_PHPBB') )
{
die("Hacking attempt");
}

#
#-----[ AFTER, ADD ]------------------------------------------
#
define('MODULES_TABLE', $table_prefix . 'stats_modules');
define('STATS_CONFIG_TABLE', $table_prefix . 'stats_config');
meine Datei
if ( !defined('IN_PHPBB') )
{
die("Hacking attempt");define('MODULES_TABLE', $table_prefix . 'stats_modules');
define('STATS_CONFIG_TABLE', $table_prefix . 'stats_config');

}
und nochmal dein vorschlag

if ( !defined('IN_PHPBB') )
{
die("Hacking attempt");
}

define('MODULES_TABLE', $table_prefix . 'stats_modules');
define('STATS_CONFIG_TABLE', $table_prefix . 'stats_config');

Verfasst: 30.03.2003 17:04
von pinki78
hab das so eingebaut wie du es geschrieben hast !!!
if ( !defined('IN_PHPBB') )
{
die("Hacking attempt");
}

define('MODULES_TABLE', $table_prefix . 'stats_modules');
define('STATS_CONFIG_TABLE', $table_prefix . 'stats_config');
}
nun erscheint folgender Fehler
Parse error: parse error, unexpected '}' in /home/toyotas/public_html/forum/includes/constants.php on line 30
phpBB : Critical Error

Could not query config information

DEBUG MODE

SQL Error : 1146 Table 'toyotas_xmb1.CONFIG_TABLE' doesn't exist

SELECT * FROM CONFIG_TABLE

Line : 176
File : /home/toyotas/public_html/forum/common.php

Verfasst: 30.03.2003 17:27
von pinki78
hab jetzt alle snoch mal neu gemacht bare der Fehler bleibt der ursrüngliche


Hilfe !!!!

Verfasst: 30.03.2003 17:31
von Acyd Burn
Augen auf, mein constants kauf:
#-----[ OPEN ]------------------------------------------
#
includes/constants.php

#
#-----[ FIND ]------------------------------------------
#
if ( !defined('IN_PHPBB') )
{
die("Hacking attempt");
}

#
#-----[ AFTER, ADD ]------------------------------------------
#
define('MODULES_TABLE', $table_prefix . 'stats_modules');
define('STATS_CONFIG_TABLE', $table_prefix . 'stats_config');
FIND:
if ( !defined('IN_PHPBB') )
{
die("Hacking attempt");
}
AFTER, ADD (WICHTIG, AFTER heißt DANACH, also NACH der geschlossenen geschweiften Klammer):
define('MODULES_TABLE', $table_prefix . 'stats_modules');
define('STATS_CONFIG_TABLE', $table_prefix . 'stats_config');
Resultat:
if ( !defined('IN_PHPBB') )
{
die("Hacking attempt");
}
define('MODULES_TABLE', $table_prefix . 'stats_modules');
define('STATS_CONFIG_TABLE', $table_prefix . 'stats_config');
Du hast bei dir noch am ende die geschweifte klammer.

PHP ist SEHR genau... ein falsches Zeichen, und es geht nicht, deshalb soll man auch immer genau lesen.

Verfasst: 30.03.2003 17:38
von saerdnaer
if ( !defined('IN_PHPBB') )
{
die("Hacking attempt");
}

define('MODULES_TABLE', $table_prefix . 'stats_modules');
define('STATS_CONFIG_TABLE', $table_prefix . 'stats_config');
}
die rote klammer muss weg!

Verfasst: 30.03.2003 17:46
von pinki78
besten dank jetzt geht es, super !!!

P.S. wer lesen kann ist klar im Vorteil :oops: