Seite 1 von 1

Enhanced Poll - Problem mit dem functions_post.php

Verfasst: 10.10.2005 18:16
von reebell
Hallo,

ich habe ein kleines Problem mit der Umfrage-Modifikation. Solange ich mit der Originaldatei functions_post.php arbeite sehe ich die Endzeit usw., jedoch kann ich dann die Anzeige für die Ergebnisse nicht ausblenden. Ich vermute mal das es mit dieser Datei zu tun hat. Wenn ich dann die bearbeitete Datei einbinde kann ich im Forum keine Antworten mehr erstellen und auch keine Sachen mehr edden.

Folgende Fehlermeldung erhalte ich immer:
Parse error: parse error, unexpected ',' in /usr/export/www/vhosts/funnetwork/hosting/reebell/phpBB2/includes/functions_post.php on line 294
Hier mal meine Zeile aus dieser Datei:
$sql = (!$post_data['has_poll']) ? "INSERT INTO " . VOTE_DESC_TABLE . " (topic_id, vote_text, vote_start, vote_length, show_endtime, show_results) VALUES ($topic_id, '$poll_title', $current_time, " . ($poll_length * 86400) . , $show_endtime, $show_results")" : "UPDATE " . VOTE_DESC_TABLE . " SET vote_text = '$poll_title', vote_length = " . ($poll_length * 86400) . ", show_endtime = $show_endtime, show_results = $show_results WHERE topic_id = $topic_id";

Ich habe da schon versucht es ein bißchen zu ändern, aber ohne Erfolg.
:roll:
Falls jemand die Datei haben möchte, hier der Link zum Download:
functions_post.php

Vielen Dank für eure Hilfe

Verfasst: 10.10.2005 18:50
von MartinITM
Hi,

ersetze doch mal die Zeile durch

Code: Alles auswählen

$sql = (!$post_data['has_poll']) ? "INSERT INTO " . VOTE_DESC_TABLE . " (topic_id, vote_text, vote_start, vote_length, show_endtime, show_results) VALUES ($topic_id, '$poll_title', $current_time, " . ($poll_length * 86400) . "," . $show_endtime . "," . $show_results")" : "UPDATE " . VOTE_DESC_TABLE . " SET vote_text = '$poll_title', vote_length = " . ($poll_length * 86400) . ", show_endtime = $show_endtime, show_results = $show_results WHERE topic_id = $topic_id";
habe nur aus den ,

Code: Alles auswählen

. "," .
gemacht.

Martin