Welcome, Guest. Please Login or Register.
May 29, 2025, 12:59:45 PM
Home Help Search Log in Register
News: SMF is the next generation in forum software, almost completely re-written from the ground up, make sure you don't fall for cheap imitations that suffer from feature bloat!

YaBB SE Community  |  German User Help  |  Hilfe zu YaBB SE  |  Voting um mehr als 8 Möglichkeiten erweitern? « previous next »
Pages: [1] 2 Reply Ignore Print
Author Topic: Voting um mehr als 8 Möglichkeiten erweitern?  (Read 1638 times)
tOsE
Noobie
*
Posts: 34


give me ONE pixel..

ICQ - 43160564
Voting um mehr als 8 Möglichkeiten erweitern?
« on: August 27, 2002, 08:24:23 PM »
Reply with quote


Kurze Frage: kann man das Voting um mehr als nur 8 Auswahlmöglichkeiten erweitern? Wenn ja, wie?

Ich danke Euch :)
Logged
Horseman
YaBB God
*****
Posts: 784


'MAS VALE CABALLO QUE CAUDAL!'

ICQ - 44729151 WWW
Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #1 on: August 27, 2002, 09:25:21 PM »
Reply with quote

machbar ist es.
die tabelle polls müsste um entsprechende felder erweitert werden.
die datei poll.php dann auf diese erweiterung ebenfalls angepasst werden.  ;)
wäre ein MOD wert "add more polls"

hast du es eilig damit?

br
hm
« Last Edit: August 27, 2002, 09:26:07 PM by Horseman » Logged
tOsE
Noobie
*
Posts: 34


give me ONE pixel..

ICQ - 43160564
Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #2 on: August 28, 2002, 04:04:24 AM »
Reply with quote

Danke erst einmal für Deine schnelle Antwort.
Eilig ist es schon, ich habe mir den code schonmal angeschaut, bin aber nicht wirklich schlau daraus geworden. Das mod sollte schon die nächsten Tage stehen - das wäre geil..   8)
Logged
Horseman
YaBB God
*****
Posts: 784


'MAS VALE CABALLO QUE CAUDAL!'

ICQ - 44729151 WWW
Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #3 on: August 28, 2002, 01:58:53 PM »
Reply with quote

wieviele fragen/antworten stellst du dir denn so vor?
16/24/32 oder wie auch immer?

brauchst es direkt als MOD oder reicht es dir (auf die schnelle) auch wenn ich dir nur die erforderlichen änderungen poste?(brauchst dann ein tool wie phpmyadmin)

habe es mal auf 16 möglichkeiten erweitert

kannst du es dir ansehen, und mal deine stimme abgeben  ;)
http://212.227.253.250/testfo/index.php?board=8;action=display;threadid=638;start=0

wenn also 16 reichen poste ich dir die änderungen mal.
sobald ich dazu komme schreibe ich das MOD, kann aber noch 1 tag dauern.

br
hm
« Last Edit: August 28, 2002, 02:24:05 PM by Horseman » Logged
tOsE
Noobie
*
Posts: 34


give me ONE pixel..

ICQ - 43160564
Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #4 on: August 28, 2002, 02:29:22 PM »
Reply with quote

10 - 24 wären toll  :)

Bei meiner aktuellen Umfrage brächte ich genau 9 (*g*) und 8 stehen nur zur Verfügung - aber mehr als 9 kann nie schaden, man muss sie ja nicht nutzen..

phpMyAdmin steht mir zur Verfügung - als MOD vielleicht später mal falls andere Fragen - die Änderungen kann ich selbst vornehmen...vorausgesetzt ich weiss wo und wie  ;)

Danke vielmals für Deine Hilfe!
« Last Edit: August 28, 2002, 02:30:37 PM by tOsE » Logged
Horseman
YaBB God
*****
Posts: 784


'MAS VALE CABALLO QUE CAUDAL!'

ICQ - 44729151 WWW
Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #5 on: August 28, 2002, 02:57:09 PM »
Reply with quote

keine ursache, kann es selber auch brauchen  ;)

Die erforderlichen Änderungen um mehr als 8 Voting Möglichkeiten zu haben:

Step 1:
Erweitere Die Tabelle POLLS um die gewünschte ,,Mehranzahl"  an Optionen und Votes.
Benutze dafür die Vorgaben wie Du diese bereits bei den 8 angelegten findest!

Step 2:[/]
Öffne die Display.php (Sources/ ) und nehme folgenden Änderungen vor:
<edit file>
Sources/Display.php
</edit file>

<search for>
$request = mysql_query("SELECT question,votingLocked,votedMemberIDs,option1,option2,option3,
option4,option5,option6,option7,option8,
votes1,votes2,votes3,votes4,votes5,
votes6,votes7,votes8 FROM {$db_prefix}
polls WHERE ID_POLL='$topicinfo[ID_POLL]' LIMIT 1");
</search for>

setze hier die gewünschte anzahl an optionen und
 votes hinzu (option9, option10, .... votes9, votes10,....)

<search for>
$totalvotes =$pollinfo['votes1']+$pollinfo['votes2']+$pollinfo['votes3']
+$pollinfo['votes4']+$pollinfo['votes5']+$pollinfo['votes6']
+$pollinfo['votes7']+$pollinfo['votes8'];
</search for>

hier ebenfalls die anzahl, wie gewünscht hinzufügen
 (+$pollinfo[,votes9']+$pollinf[,votes10']....)

<search for>
for ($i = 1; $i <= 8; $i++)
</search for>

ändere die 8 auf die richtige anzahl

<search for>
for ($i = 1; $i <= 8; $i++)
</search for>

ändere die 8 auf die richtige anzahl
dann nimm dir Polls.php aus dem
Source Verzeichiss und ändere wie folgt:

<edit file>
Sources/Polls.php
</edit file>

<search for>
$txt[yse22] 8: <input type="text" name="option8" size="25"><br>
</search for>

füge die gewünschte anzahl hinzu

<search for>
$option9 = mysql_escape_string($option9);
</search for>

füge die gewünschte anzahl hinzu

<search for>
   $request = mysql_query("INSERT INTO {$db_prefix}polls
(question,option1,option2,option3,option4,
option5,option6,option7,option8, votedMemberIDs)
VALUES ('$question','$option1','$option2','$option3'
,'$option4','$option5','$option6','$option7','$option8','')");

</search for>

erweitere die angaben um die gewünschte
anzahl optionen

<search for>
   $request = mysql_query("SELECT p.ID_POLL,p.question,p.option1,p.option2,p.option3,
p.option4,p.option5,p.option6,p.option7,p.option8,
p.votes1,p.votes2,p.votes3,p.votes4,p.votes5,
p.votes6,p.votes7,p.votes8 FROM {$db_prefix}
polls as p,{$db_prefix}topics as t WHERE
(p.ID_POLL=t.ID_POLL && t.ID_TOPIC='$threadid') LIMIT 1");
</search for>

erweitere die angaben um die gewünschte anzahl optionen

<search for>
$txt[yse22] 8: <input type="text" name="option8" size="25" value="$pollinfo[option8]">
($pollinfo[votes8] $txt[yse42])<br>
</search for>

erweitere die angaben um die gewünschte
anzahl optionen

<search for>
   global $question,$option1,$option2,$option3,$option4,
$option5,$option6,$option7,$option8
$resetVoteCount;
</search for>

erweitere die angaben um die gewünschte
anzahl optionen

<search for>
   $request = mysql_query("UPDATE {$db_prefix}
polls SET votedMemberIDs='',votes1=0,votes2=0,votes3=0,
votes4=0,votes5=0,votes6=0,votes7=0,votes8=0  WHERE ID_POLL='$poll' $doLimitOne");
</search for>

erweitere die angaben um die gewünschte
anzahl optionen

<search for>
   for ($i = 1; $i<=8;$i++)
</search for>

Ändere die 8 auf die gewünschte Anzahl


<search for>
        $option8 = mysql_escape_string($option8);
</search for>

erweitere die angaben um die gewünschte
anzahl optionen

<search for>
   $request = mysql_query("UPDATE {$db_prefix}polls SET option1='$option1',option2='$option2',option3='$option3',
option4='$option4',option5='$option5',option6='$option6',
option7='$option7',option8='$option8',
 question='$question' WHERE ID_POLL='$poll' $doLimitOne");
</search for>
[
erweitere die angaben um die gewünschte
anzahl optionen

das war es schon...

br
hm


« Last Edit: August 28, 2002, 03:05:22 PM by Horseman » Logged
tOsE
Noobie
*
Posts: 34


give me ONE pixel..

ICQ - 43160564
Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #6 on: August 29, 2002, 06:09:11 AM »
Reply with quote

Yo, sehr geil - hat alles FUNKTIONIERT! *freu*

DANKE DANKE DANKE  :)
Logged
Horseman
YaBB God
*****
Posts: 784


'MAS VALE CABALLO QUE CAUDAL!'

ICQ - 44729151 WWW
Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #7 on: August 29, 2002, 09:26:36 AM »
Reply with quote

Quote from: tOsE on August 28, 2002, 02:29:22 PM10 - 24 wären toll  :)
 - als MOD vielleicht später mal falls andere Fragen - die Änderungen kann ich selbst vornehmen...

freut mich das alles geklappt hat  :)
werde mit dem MOD warten, ob überhaupt eine grösseres interesse an dieser funktion besteht.

br
hm
Logged
Daniel D.
Mod Team
YaBB God
*****
Posts: 2935


Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #8 on: August 29, 2002, 01:42:19 PM »
Reply with quote

Äääh, wieso wartest Du ?? Immer her damit ! Ist doch gut. :D !!
Logged

Horseman
YaBB God
*****
Posts: 784


'MAS VALE CABALLO QUE CAUDAL!'

ICQ - 44729151 WWW
Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #9 on: August 29, 2002, 01:47:53 PM »
Reply with quote

na ok, dann mache ich es am abend fertig wenn ich vom reiten zurück bin und gebe dir dann bescheid.

br
hm
Logged
Fred066
Full Member
***
Posts: 143


I'm a llama!

WWW
Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #10 on: August 29, 2002, 06:16:04 PM »
Reply with quote

Ähm, Klopf-Klopf, ich hätte diesen Mod auch sehr gerne Bitte! Danke!
Logged
Horseman
YaBB God
*****
Posts: 784


'MAS VALE CABALLO QUE CAUDAL!'

ICQ - 44729151 WWW
Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #11 on: August 29, 2002, 06:22:43 PM »
Reply with quote

der MOD ist fertig  :D
habe daniel d. gebeten noch mal einen "test" zu machen und dann geben wir ihn frei.
wirst den eintrag dann im board für die mods finden.

denke es wird noch heute abend sein.

br HM

Logged
Daniel D.
Mod Team
YaBB God
*****
Posts: 2935


Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #12 on: August 29, 2002, 07:11:59 PM »
Reply with quote

Jo, in ein paar Minuten...
Logged

Fred066
Full Member
***
Posts: 143


I'm a llama!

WWW
Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #13 on: August 29, 2002, 08:02:30 PM »
Reply with quote

Ich möchte mich hiermit bei Euch bedanken!
Logged
Daniel D.
Mod Team
YaBB God
*****
Posts: 2935


Re:Voting um mehr als 8 Möglichkeiten erweitern?
« Reply #14 on: August 30, 2002, 05:31:24 PM »
Reply with quote

Ja, die paar Minuten waren aber etwas länger :-[. Ich war auf meinem Bett eingeschlafen ;D...
Logged

Pages: [1] 2 Reply Ignore Print 
YaBB SE Community  |  German User Help  |  Hilfe zu YaBB SE  |  Voting um mehr als 8 Möglichkeiten erweitern? « previous - next »
 


Powered by MySQL Powered by PHP YaBB SE Community | Powered by YaBB SE
© 2001-2003, YaBB SE Dev Team. All Rights Reserved.
SMF 2.1.4 © 2023, Simple Machines
Valid XHTML 1.0! Valid CSS

Page created in 0.040 seconds with 20 queries.