Seite 1 von 1

Stimmungsmod

Verfasst: 01.06.2006 15:14
von Tost-Er
Bin beim Stimungsmod am verzweifeln,
meine Stimmung ist etwas so :cry: *g

FEHLERMELDUNG im Explorer:

Couldn't query themes table

DEBUG MODE

SQL Error : 1054 Unknown column 'emotion_id' in 'field list'

SELECT emotion_id, emotion_name FROM phpbb_emotions ORDER BY emotion_id

Line : 126
File : functions_selects.php
------------------------------------------------------------------------------------------------------
Da wäre die Line 126 von functions_selects.php:

message_die(GENERAL_ERROR, "Couldn't query themes table", "", __LINE__, __FILE__, $sql);


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

In der Datenbank habe ich eine Tabelle phpbb_emotion mit 19 Felder erstellt. Im phpmyadmin, habe ich im

"Feld" immer die jeweiligen Namen reingeschrieben. (not selected, Agressive, Amazed, Angry, Bored, Busy, Cool usw.)

"Typ" ist bei allen Felder mit VARCHAR(100) versehen.

"Attribute" alles leer.

"Null" überall mit nein versehen.

In "Standart" und "Extra" ist alles leer.

Was ist nun falsch?
Fehlen noch Tabellen oder Felder in der DB? :roll:


Danke!

Verfasst: 01.06.2006 15:23
von Simlau
not selected, Agressive, Amazed, Angry, Bored, Busy, Cool usw.
Auch das Feld emotion_id angelegt?

Verfasst: 03.06.2006 07:10
von Tost-Er
thx simlau,
habe nun das Feld emotion_id, emotion_name hinzugefügt und
die Fehlermeldung ist verschwunden.

Nun folgendes Problem:
sobald ich auf mein Profil klicke, folgt diese Fehlermeldung:
-------------------------------------------------------------------------------------------
Parse error: parse error, unexpected ';' in /home/www/web112/html/iq-test1/includes/usercp_register.php on line 136
-------------------------------------------------------------------------------------------

Line136:
$emotion = ( isset($HTTP_POST_VARS['emotion']) ) ? intval ($HTTP_POST_VARS['emotion']) : 0;
-------------------------------------------------------------------------------------------

Etwas mehr Code:
$signature = (isset($signature)) ? str_replace(// Start add - Emotion MOD
$emotion = ( isset($HTTP_POST_VARS['emotion']) ) ? intval ($HTTP_POST_VARS['emotion']) : 0;
// End add - Emotion MOD'<br />', "\n", $signature) : '';
$signature_bbcode_uid = '';

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

Nun möchte ich noch Hinzufügen, im Installation Text vom
Stimmungsmod steht,
#-----[ OPEN ]------------------------------------------------
#
includes/usercp_register.php

#
#-----[ FIND ]------------------------------------------------
#
$signature = str_replace(

#
#-----[ AFTER, ADD ]------------------------------------------
#
// Start add - Emotion MOD
$emotion = ( isset($HTTP_POST_VARS['emotion']) ) ? intval ($HTTP_POST_VARS['emotion']) : 0;
// End add - Emotion MOD

#

Wie oben im Code zu sehe, ist es nicht $signature = str_replace(
sondern $signature = (isset($signature)) ? str_replace(

Kann ja sein, dass da ein Problem vorliegt.
Keine Ahnung :roll:


Wenn ich den Teil den ich einfügen sollte // Start add - Emotion MOD
$emotion = ( isset($HTTP_POST_VARS['emotion']) ) ? intval ($HTTP_POST_VARS['emotion']) : 0;
// End add - Emotion MOD
entferne, dann ist die Fehlermeldung weg, doch im Profil ist das auswälen der Stimmung nicht möglich.
Ausser zwei nacheinander folgenden Linien, die weiter unten im Profil zu sehen ist, fällt mir keine veränderung auf.


Im voraus, Danke!

Verfasst: 17.06.2006 03:41
von Tost-Er
irgendwie schade, dass mir niemand helfen kann/will.

Gibt es möglicherweise einen Mod, welcher neu geschrieben wurde?
Hat jemand kürzlich diesen Mod ausprobiert und anhand der Beschreibung erfolgreich eingebaut?

Verfasst: 17.06.2006 04:12
von Mahony
Hallo

Versuchs mal so (etwas mehr Code angegeben)

Code: Alles auswählen

	while( list($var, $param) = @each($trim_var_list) )
	{
		if ( !empty($HTTP_POST_VARS[$param]) )
		{
			$$var = trim($HTTP_POST_VARS[$param]);
		}
	}

	$signature = (isset($signature)) ? str_replace('<br />', "\n", $signature) : '';
	// Start add - Emotion MOD
$emotion = ( isset($HTTP_POST_VARS['emotion']) ) ? intval ($HTTP_POST_VARS['emotion']) : 0;
// End add - Emotion MOD

Die betreffende Stelle sollte also so Aussehen:

Code: Alles auswählen

	$signature = (isset($signature)) ? str_replace('<br />', "\n", $signature) : '';
	// Start add - Emotion MOD
$emotion = ( isset($HTTP_POST_VARS['emotion']) ) ? intval ($HTTP_POST_VARS['emotion']) : 0;
// End add - Emotion MOD

Grüße: Mahony

Verfasst: 17.06.2006 11:43
von darkon
Probier doch mal den Mood-Mod von Austin aus.

http://phpbb-tweaks.com/

Der funktioniert tadellos bei mir :)