[Problem] nach einbau von mod messageicon
Forumsregeln
phpBB 2.0 hat das Ende seiner Lebenszeit überschritten
phpBB 2.0 wird nicht mehr aktiv unterstützt. Insbesondere werden - auch bei Sicherheitslücken - keine Patches mehr bereitgestellt. Der Einsatz von phpBB 2.0 erfolgt daher auf eigene Gefahr. Wir empfehlen einen Umstieg auf phpBB 3.0, welches aktiv weiterentwickelt wird und für welches regelmäßig Updates zur Verfügung gestellt werden.
phpBB 2.0 hat das Ende seiner Lebenszeit überschritten
phpBB 2.0 wird nicht mehr aktiv unterstützt. Insbesondere werden - auch bei Sicherheitslücken - keine Patches mehr bereitgestellt. Der Einsatz von phpBB 2.0 erfolgt daher auf eigene Gefahr. Wir empfehlen einen Umstieg auf phpBB 3.0, welches aktiv weiterentwickelt wird und für welches regelmäßig Updates zur Verfügung gestellt werden.
[Problem] nach einbau von mod messageicon
hallo
bekomme seit einabu des mods folgende fehlermeldung:
Error in posting
DEBUG MODE
SQL Error : 1064 You have an error in your SQL syntax near ')' at line 1
INSERT INTO phpbb_topics (topic_title, topic_poster, topic_time, forum_id, topic_status, topic_type, topic_vote, topic_icon) VALUES ('test', 2, 1044560479, 1, 0, 0, 0, )
Line : 256
File : /home/dasmedbb/www.das-megaei.de/Forum/includes/functions_post.php
in der zeile habe ich jedoch nix verändert.
hier die besagte zeile:
message_die(GENERAL_ERROR, 'Error in posting', '', __LINE__, __FILE__, $sql);
hier mal die zeilen die man ändern soll in der includes/function_post.php
hpBB2/includes/functions_post.php
#
#-----[ FIND ]------------------------------------------
#
function submit_post($mode, &$post_data, &$message, &$meta, &$forum_id, &$topic_id, &$post_id, &$poll_id, &$topic_type, &$bbcode_on, &$html_on, &$smilies_on, &$attach_sig, &$bbcode_uid, &$post_username, &$post_subject, &$post_message, &$poll_title, &$poll_options, &$poll_length)
#
#-----[ REPLACE WITH ]------------------------------------------
#
function submit_post($mode, &$post_data, &$message, &$meta, &$forum_id, &$topic_id, &$post_id, &$poll_id, &$topic_type, &$bbcode_on, &$html_on, &$smilies_on, &$attach_sig, &$bbcode_uid, &$post_username, &$post_subject, &$post_message, &$poll_title, &$poll_options, &$poll_length, &$MsgIcon)
#
#-----[ FIND ]------------------------------------------
#
$sql = ( $mode != "editpost" ) ? "INSERT INTO " . TOPICS_TABLE . " (topic_title, topic_poster, topic_time, forum_id, topic_status, topic_type, topic_vote) VALUES ('$post_subject', " . $userdata['user_id'] . ", $current_time, $forum_id, " . TOPIC_UNLOCKED . ", $topic_type, $topic_vote)" : "UPDATE " . TOPICS_TABLE . " SET topic_title = '$post_subject', topic_type = $topic_type, topic_vote = $topic_vote WHERE topic_id = $topic_id";
#
#-----[ REPLACE WITH ]------------------------------------------
#
$sql = ( $mode != "editpost" ) ? "INSERT INTO " . TOPICS_TABLE . " (topic_title, topic_poster, topic_time, forum_id, topic_status, topic_type, topic_vote, topic_icon) VALUES ('$post_subject', " . $userdata['user_id'] . ", $current_time, $forum_id, " . TOPIC_UNLOCKED . ", $topic_type, $topic_vote, $MsgIcon)" : "UPDATE " . TOPICS_TABLE . " SET topic_title = '$post_subject', topic_type = $topic_type, topic_vote = $topic_vote, topic_icon = $MsgIcon WHERE topic_id = $topic_id";
#
#-----[ FIND ]------------------------------------------
#
$sql = ( $mode != "editpost" ) ? "INSERT INTO " . POSTS_TABLE . " (topic_id, forum_id, poster_id, post_username, post_time, poster_ip, enable_bbcode, enable_html, enable_smilies, enable_sig) VALUES ($topic_id, $forum_id, " . $userdata['user_id'] . ", '$post_username', $current_time, '$user_ip', $bbcode_on, $html_on, $smilies_on, $attach_sig)" : "UPDATE " . POSTS_TABLE . " SET enable_bbcode = $bbcode_on, enable_html = $html_on, enable_smilies = $smilies_on, enable_sig = $attach_sig" . $edited_sql . " WHERE post_id = $post_id";
#
#-----[ REPLACE WITH ]------------------------------------------
#
$sql = ( $mode != "editpost" ) ? "INSERT INTO " . POSTS_TABLE . " (topic_id, forum_id, poster_id, post_username, post_time, poster_ip, enable_bbcode, enable_html, enable_smilies, enable_sig, post_icon) VALUES ($topic_id, $forum_id, " . $userdata['user_id'] . ", '$post_username', $current_time, '$user_ip', $bbcode_on, $html_on, $smilies_on, $attach_sig, $MsgIcon)" : "UPDATE " . POSTS_TABLE . " SET enable_bbcode = $bbcode_on, enable_html = $html_on, enable_smilies = $smilies_on, enable_sig = $attach_sig" . $edited_sql . ", post_icon = $MsgIcon WHERE post_id = $post_id";
wer kann mir da mal weiterhelfen ?
bekomme seit einabu des mods folgende fehlermeldung:
Error in posting
DEBUG MODE
SQL Error : 1064 You have an error in your SQL syntax near ')' at line 1
INSERT INTO phpbb_topics (topic_title, topic_poster, topic_time, forum_id, topic_status, topic_type, topic_vote, topic_icon) VALUES ('test', 2, 1044560479, 1, 0, 0, 0, )
Line : 256
File : /home/dasmedbb/www.das-megaei.de/Forum/includes/functions_post.php
in der zeile habe ich jedoch nix verändert.
hier die besagte zeile:
message_die(GENERAL_ERROR, 'Error in posting', '', __LINE__, __FILE__, $sql);
hier mal die zeilen die man ändern soll in der includes/function_post.php
hpBB2/includes/functions_post.php
#
#-----[ FIND ]------------------------------------------
#
function submit_post($mode, &$post_data, &$message, &$meta, &$forum_id, &$topic_id, &$post_id, &$poll_id, &$topic_type, &$bbcode_on, &$html_on, &$smilies_on, &$attach_sig, &$bbcode_uid, &$post_username, &$post_subject, &$post_message, &$poll_title, &$poll_options, &$poll_length)
#
#-----[ REPLACE WITH ]------------------------------------------
#
function submit_post($mode, &$post_data, &$message, &$meta, &$forum_id, &$topic_id, &$post_id, &$poll_id, &$topic_type, &$bbcode_on, &$html_on, &$smilies_on, &$attach_sig, &$bbcode_uid, &$post_username, &$post_subject, &$post_message, &$poll_title, &$poll_options, &$poll_length, &$MsgIcon)
#
#-----[ FIND ]------------------------------------------
#
$sql = ( $mode != "editpost" ) ? "INSERT INTO " . TOPICS_TABLE . " (topic_title, topic_poster, topic_time, forum_id, topic_status, topic_type, topic_vote) VALUES ('$post_subject', " . $userdata['user_id'] . ", $current_time, $forum_id, " . TOPIC_UNLOCKED . ", $topic_type, $topic_vote)" : "UPDATE " . TOPICS_TABLE . " SET topic_title = '$post_subject', topic_type = $topic_type, topic_vote = $topic_vote WHERE topic_id = $topic_id";
#
#-----[ REPLACE WITH ]------------------------------------------
#
$sql = ( $mode != "editpost" ) ? "INSERT INTO " . TOPICS_TABLE . " (topic_title, topic_poster, topic_time, forum_id, topic_status, topic_type, topic_vote, topic_icon) VALUES ('$post_subject', " . $userdata['user_id'] . ", $current_time, $forum_id, " . TOPIC_UNLOCKED . ", $topic_type, $topic_vote, $MsgIcon)" : "UPDATE " . TOPICS_TABLE . " SET topic_title = '$post_subject', topic_type = $topic_type, topic_vote = $topic_vote, topic_icon = $MsgIcon WHERE topic_id = $topic_id";
#
#-----[ FIND ]------------------------------------------
#
$sql = ( $mode != "editpost" ) ? "INSERT INTO " . POSTS_TABLE . " (topic_id, forum_id, poster_id, post_username, post_time, poster_ip, enable_bbcode, enable_html, enable_smilies, enable_sig) VALUES ($topic_id, $forum_id, " . $userdata['user_id'] . ", '$post_username', $current_time, '$user_ip', $bbcode_on, $html_on, $smilies_on, $attach_sig)" : "UPDATE " . POSTS_TABLE . " SET enable_bbcode = $bbcode_on, enable_html = $html_on, enable_smilies = $smilies_on, enable_sig = $attach_sig" . $edited_sql . " WHERE post_id = $post_id";
#
#-----[ REPLACE WITH ]------------------------------------------
#
$sql = ( $mode != "editpost" ) ? "INSERT INTO " . POSTS_TABLE . " (topic_id, forum_id, poster_id, post_username, post_time, poster_ip, enable_bbcode, enable_html, enable_smilies, enable_sig, post_icon) VALUES ($topic_id, $forum_id, " . $userdata['user_id'] . ", '$post_username', $current_time, '$user_ip', $bbcode_on, $html_on, $smilies_on, $attach_sig, $MsgIcon)" : "UPDATE " . POSTS_TABLE . " SET enable_bbcode = $bbcode_on, enable_html = $html_on, enable_smilies = $smilies_on, enable_sig = $attach_sig" . $edited_sql . ", post_icon = $MsgIcon WHERE post_id = $post_id";
wer kann mir da mal weiterhelfen ?
- biototo
- Mitglied
- Beiträge: 803
- Registriert: 10.04.2002 09:51
- Wohnort: Düren - Rheinland (zw Köln u. Aachen)
- Kontaktdaten:
Dasproblem liegt hier
und zwar darf am ende kein KOmma stehen sondern, da muss ein wert stehen. Aufgrund der Tatsache, das da nichts steht, aber was stehen sollte, weil es 8 Spalten sind aber nur 7 werte, solltest du ncohmal nachschauen, ob du auch wirklich alles korrekt verändert hast, weiles scheint, als wenn in $MsgIcon ncihts drin steht .... check das mal !!!
Code: Alles auswählen
INSERT INTO phpbb_topics (topic_title, topic_poster, topic_time, forum_id, topic_status, topic_type, topic_vote, topic_icon) VALUES ('test', 2, 1044560479, 1, 0, 0, 0, )
also das heisst der fehler muss nicht in der includes/functions_post.php stehen sondern kann in einer der anderen stecken ?
templates/subSilver/posting_body.tpl
posting.php
viewforum.php
templates/subSilver/viewforum_body.tpl
viewtopic.php
templates/subSilver/viewtopic_body.tpl
na toll wo ich auch sogut mit den sachen klar komme naja also die functions_post.php habe ich nochmal überarbeitet da steht jetzt alles so wie es sein soll.
somit bleiben noch 6 dateien die ich kontrollieren muss
templates/subSilver/posting_body.tpl
posting.php
viewforum.php
templates/subSilver/viewforum_body.tpl
viewtopic.php
templates/subSilver/viewtopic_body.tpl
na toll wo ich auch sogut mit den sachen klar komme naja also die functions_post.php habe ich nochmal überarbeitet da steht jetzt alles so wie es sein soll.
somit bleiben noch 6 dateien die ich kontrollieren muss
so ich muss was wissen zum einbau (so langsam komme ich mir vor wei ein spammer)
es heisst zb
phpBB2/posting.php
#
#-----[ FIND ]------------------------------------------
#
$refresh = $preview || $poll_add || $poll_edit || $poll_delete;
#
#-----[ AFTER, ADD ]------------------------------------------
#
if ($MsgIcon)
$MsgIconChecked = $MsgIcon;
else
$MsgIconChecked = 1;
so meine frage danach einfügen...das if ($MsgIcon) usw inter dem ; oder das ganze zwischen delete und ;
ich frage lieber so als wenn ich alles wieder verkehrt mache
es heisst zb
phpBB2/posting.php
#
#-----[ FIND ]------------------------------------------
#
$refresh = $preview || $poll_add || $poll_edit || $poll_delete;
#
#-----[ AFTER, ADD ]------------------------------------------
#
if ($MsgIcon)
$MsgIconChecked = $MsgIcon;
else
$MsgIconChecked = 1;
so meine frage danach einfügen...das if ($MsgIcon) usw inter dem ; oder das ganze zwischen delete und ;
ich frage lieber so als wenn ich alles wieder verkehrt mache
..nach der kompletten Zeile.
Übrigens, sollte der Fehler in der functions_post.php zu finden sein.
Code: Alles auswählen
$refresh = $preview || $poll_add || $poll_edit || $poll_delete;
hehe das sagst jetz wo ich voll dabei bin die posting.php durchsuche
inder der functions_post.php versteh ich nicht denke alles soweit richtig gemacht zu haben
http://www.ssmf.net/functions_post.rar da hab ich die mal abgelegt.
also wenn du so gut wärst und könntest evtl bitte mal nachsehen ?
und mir den fehler sagen den ich gemacht haben soll ?
inder der functions_post.php versteh ich nicht denke alles soweit richtig gemacht zu haben
http://www.ssmf.net/functions_post.rar da hab ich die mal abgelegt.
also wenn du so gut wärst und könntest evtl bitte mal nachsehen ?
und mir den fehler sagen den ich gemacht haben soll ?
naja ich werds probieren
original sieht so aus
$html_on = ( $post_info['enable_html'] ) ? true : false;
$bbcode_on = ( $post_info['enable_bbcode'] ) ? true : false;
$smilies_on = ( $post_info['enable_smilies'] ) ? true : false;
}
else
{
und jetzt soll das hier rein
#
#-----[ FIND ]------------------------------------------
#
$smilies_on = ( $post_info['enable_smilies'] ) ? true : false;
#
#-----[ AFTER, ADD ]------------------------------------------
#
switch ($post_info['post_icon']) {
case 2 : $MsgIconChecked = 2; break;
case 3 : $MsgIconChecked = 3; break;
case 4 : $MsgIconChecked = 4; break;
case 5 : $MsgIconChecked = 5; break;
case 6 : $MsgIconChecked = 6; break;
case 7 : $MsgIconChecked = 7; break;
case 8 : $MsgIconChecked = 8; break;
case 9 : $MsgIconChecked = 9; break;
case 10 : $MsgIconChecked = 10; break;
case 11 : $MsgIconChecked = 11; break;
case 12 : $MsgIconChecked = 12; break;
case 13 : $MsgIconChecked = 13; break;
case 14 : $MsgIconChecked = 14; break;
default : $MsgIconChecked = 1; break;
}
so wenn ich das hinter dieses false; einfüge dann habe ich am ende von den ganzen...2 mal diese klammer }
soll das so richtig sein ?
manman in der anleitung steht 20 minuten
und wie lange sitze ich an diesen einen mod
egal hauptsache funktioniert
...is scho richtig (nach false;), denn bei..
..findet sich ja die erste Klammer, somit das Ganze dann geschlossen wäre.
Code: Alles auswählen
switch ($post_info['post_icon']) {