Mehrfachauswahl Umfrage
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.
Hi ...
die functions_post.php ist in Ordnung.
suche in der posting.php
ersetze mit:
Vorher eine Sicherungskopie deiner bisherigen posting.php erstellen
Markus
die functions_post.php ist in Ordnung.
suche in der posting.php
Code: Alles auswählen
// Vote in a poll
//
if ( (!empty($HTTP_POST_VARS['vote_id'])) and (is_array($HTTP_POST_VARS['vote_id'])) and (isset($HTTP_POST_VARS['vote_id'])) )
{
$vote_option_id = intval($HTTP_POST_VARS['vote_id']);
for($i = 0; $i < $max_voting; $i++)
{
$vote_option_id = $vbn[$i];
$vote_id = $HTTP_POST_VARS['vote_id'];
$sql = "SELECT vd.vote_id, vd.vote_max
FROM " . VOTE_DESC_TABLE . " vd, " . VOTE_RESULTS_TABLE . " vr
WHERE vd.topic_id = $topic_id
AND vr.vote_id = vd.vote_id
AND vr.vote_option_id = $vote_option_id
GROUP BY vd.vote_id";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not obtain vote data for this topic', '', __LINE__, __FILE__, $sql);
}
if ( $vote_info = $db->sql_fetchrow($result) )
{
$max_vote = $vote_info['vote_max'];
}
$max_voting=count($vote_id);
if ($max_voting>$max_vote)
{
$max_voting=$max_vote;
}
for($i = 0; $i < $max_voting; $i++)
{
$vbn[$i]= $vote_id[$i];
}
$sql = "SELECT vd.vote_id
FROM " . VOTE_DESC_TABLE . " vd, " . VOTE_RESULTS_TABLE . " vr
WHERE vd.topic_id = $topic_id
AND vr.vote_id = vd.vote_id
AND vr.vote_option_id = $vote_option_id
GROUP BY vd.vote_id";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not obtain vote data for this topic', '', __LINE__, __FILE__, $sql);
}
if ( $vote_info = $db->sql_fetchrow($result) )
{
$vote_id = $vote_info['vote_id'];
$sql = "SELECT *
FROM " . VOTE_USERS_TABLE . "
WHERE vote_id = $vote_id
AND vote_user_id = " . $userdata['user_id'];
if ( !$db->sql_query($sql, END_TRANSACTION) )
{
message_die(GENERAL_ERROR, "Could not insert user_id for poll", "", __LINE__, __FILE__, $sql);
}
$message = $lang['Vote_cast'];
}
else
{
$message = $lang['Already_voted'];
}
$db->sql_freeresult($result2);
}
// $db->sql_freeresult($result);
$template->assign_vars(array(
'META' => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id") . '">')
);
$message .= '<br /><br />' . sprintf($lang['Click_view_message'], '<a href="' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id") . '">', '</a>');
message_die(GENERAL_MESSAGE, $message);
}
else
{
redirect(append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id", true));
}
}
else if ( $submit || $confirm )
Code: Alles auswählen
// Vote in a poll
//
if ( !empty($HTTP_POST_VARS['vote_id']) )
{
$vote_option_id = intval($HTTP_POST_VARS['vote_id']);
$vote_id = $HTTP_POST_VARS['vote_id'];
$sql = "SELECT vd.vote_id, vd.vote_max
FROM " . VOTE_DESC_TABLE . " vd, " . VOTE_RESULTS_TABLE . " vr
WHERE vd.topic_id = $topic_id
AND vr.vote_id = vd.vote_id
AND vr.vote_option_id = $vote_option_id
GROUP BY vd.vote_id";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not obtain vote data for this topic', '', __LINE__, __FILE__, $sql);
}
if ( $vote_info = $db->sql_fetchrow($result) )
{
$max_vote = $vote_info['vote_max'];
}
$max_voting=count($vote_id);
if ($max_voting>$max_vote)
{
$max_voting=$max_vote;
}
for($i = 0; $i < $max_voting; $i++)
{
$vbn[$i]= $vote_id[$i];
}
$sql = "SELECT vd.vote_id
FROM " . VOTE_DESC_TABLE . " vd, " . VOTE_RESULTS_TABLE . " vr
WHERE vd.topic_id = $topic_id
AND vr.vote_id = vd.vote_id
AND vr.vote_option_id = $vote_option_id
GROUP BY vd.vote_id";
if ( !($result = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not obtain vote data for this topic', '', __LINE__, __FILE__, $sql);
}
if ( $vote_info = $db->sql_fetchrow($result) )
{
$vote_id = $vote_info['vote_id'];
$sql = "SELECT *
FROM " . VOTE_USERS_TABLE . "
WHERE vote_id = $vote_id
AND vote_user_id = " . $userdata['user_id'];
if ( !($result2 = $db->sql_query($sql)) )
{
message_die(GENERAL_ERROR, 'Could not obtain user vote data for this topic', '', __LINE__, __FILE__, $sql);
}
if ( !($row = $db->sql_fetchrow($result2)) )
{
for($i = 0; $i < $max_voting; $i++)
{
$vote_option_id = $vbn[$i];
$sql = "UPDATE " . VOTE_RESULTS_TABLE . "
SET vote_result = vote_result + 1
WHERE vote_id = $vote_id
AND vote_option_id = $vote_option_id";
$vote_option_id = ''
if ( !$db->sql_query($sql, BEGIN_TRANSACTION) )
{
message_die(GENERAL_ERROR, 'Could not update poll result', '', __LINE__, __FILE__, $sql);
}
}
$sql = "UPDATE " . VOTE_DESC_TABLE . "
SET vote_voted = vote_voted + 1
WHERE vote_id = $vote_id
AND topic_id = $topic_id";
if ( !$db->sql_query($sql, BEGIN_TRANSACTION) )
{
message_die(GENERAL_ERROR, 'Could not update poll voted', '', __LINE__, __FILE__, $sql);
}
$sql = "INSERT INTO " . VOTE_USERS_TABLE . " (vote_id, vote_user_id, vote_user_ip)
VALUES ($vote_id, " . $userdata['user_id'] . ", '$user_ip')";
if ( !$db->sql_query($sql, END_TRANSACTION) )
{
message_die(GENERAL_ERROR, "Could not insert user_id for poll", "", __LINE__, __FILE__, $sql);
}
$message = $lang['Vote_cast'];
}
else
{
$message = $lang['Already_voted'];
}
$db->sql_freeresult($result2);
}
else
{
$message = $lang['No_vote_option'];
}
$db->sql_freeresult($result);
$template->assign_vars(array(
'META' => '<meta http-equiv="refresh" content="3;url=' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id") . '">')
);
$message .= '<br /><br />' . sprintf($lang['Click_view_message'], '<a href="' . append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id") . '">', '</a>');
message_die(GENERAL_MESSAGE, $message);
}
else
{
redirect(append_sid("viewtopic.$phpEx?" . POST_TOPIC_URL . "=$topic_id", true));
}
}
else if ( $submit || $confirm )

Markus
.... Telefon-Support - Schnelle Hilfe bei Hackangriffen, Modeinbau, Templateanpassung, Grafikerst., uvm.
.... Es gibt keine Probleme .... Nur neue Chancen
.... Ihr wollt ein einmaliges Template? - Prof. Templateerstellung und phpBB-Anpassungen
.... Es gibt keine Probleme .... Nur neue Chancen
.... Ihr wollt ein einmaliges Template? - Prof. Templateerstellung und phpBB-Anpassungen
Hi ...
verlinke nochmal bitte die neue posting.php
Markus
verlinke nochmal bitte die neue posting.php
Markus
.... Telefon-Support - Schnelle Hilfe bei Hackangriffen, Modeinbau, Templateanpassung, Grafikerst., uvm.
.... Es gibt keine Probleme .... Nur neue Chancen
.... Ihr wollt ein einmaliges Template? - Prof. Templateerstellung und phpBB-Anpassungen
.... Es gibt keine Probleme .... Nur neue Chancen
.... Ihr wollt ein einmaliges Template? - Prof. Templateerstellung und phpBB-Anpassungen
Ne, moment, ist diese fehlermeldung, hab mich vorher beim erstellen verschrieben:
http://www.maenumania.ch/files/posting.txt
Parse error: parse error, unexpected T_IF in /home/www/web291/html/forum/posting.php on line 869
http://www.maenumania.ch/files/posting.txt
Hi ...
suche in der posting.php
ersetze mit:
Markus
suche in der posting.php
Code: Alles auswählen
// Vote in a poll
//
if ( !empty($HTTP_POST_VARS['vote_id']) )
Code: Alles auswählen
// Vote in a poll
//
if ( (!empty($HTTP_POST_VARS['vote_id'])) and (is_array($HTTP_POST_VARS['vote_id'])) and (isset($HTTP_POST_VARS['vote_id'])) )
.... Telefon-Support - Schnelle Hilfe bei Hackangriffen, Modeinbau, Templateanpassung, Grafikerst., uvm.
.... Es gibt keine Probleme .... Nur neue Chancen
.... Ihr wollt ein einmaliges Template? - Prof. Templateerstellung und phpBB-Anpassungen
.... Es gibt keine Probleme .... Nur neue Chancen
.... Ihr wollt ein einmaliges Template? - Prof. Templateerstellung und phpBB-Anpassungen
Hi ...
Hast du zufällig noch den MOD Admin Voting eingebaut?
Verlinke mal bitte auch noch die viewtopic.php als txt-Datei.
Markus
Hast du zufällig noch den MOD Admin Voting eingebaut?
Verlinke mal bitte auch noch die viewtopic.php als txt-Datei.
Markus
.... Telefon-Support - Schnelle Hilfe bei Hackangriffen, Modeinbau, Templateanpassung, Grafikerst., uvm.
.... Es gibt keine Probleme .... Nur neue Chancen
.... Ihr wollt ein einmaliges Template? - Prof. Templateerstellung und phpBB-Anpassungen
.... Es gibt keine Probleme .... Nur neue Chancen
.... Ihr wollt ein einmaliges Template? - Prof. Templateerstellung und phpBB-Anpassungen
Hi ...
suche in der viewtopic.php
ersetze mit:
Sonst konnte ich da auch nichts finden.
Markus
suche in der viewtopic.php
Code: Alles auswählen
$poll_expires_c = $lang['Results_after'];
Code: Alles auswählen
$poll_expires_c = '';
Markus
.... Telefon-Support - Schnelle Hilfe bei Hackangriffen, Modeinbau, Templateanpassung, Grafikerst., uvm.
.... Es gibt keine Probleme .... Nur neue Chancen
.... Ihr wollt ein einmaliges Template? - Prof. Templateerstellung und phpBB-Anpassungen
.... Es gibt keine Probleme .... Nur neue Chancen
.... Ihr wollt ein einmaliges Template? - Prof. Templateerstellung und phpBB-Anpassungen