The Web Design Group

... Making the Web accessible to all.

Welcome Guest ( Log In | Register )

 
Reply to this topicStart new topic
> web poll
dannyb90
post Oct 17 2007, 04:22 PM
Post #1





Group: Members
Posts: 3
Joined: 17-October 07
Member No.: 4,084



i have been searching all day for codes but they are all different and i'm just confused! I have this simple poll...

<form method="post" action="results.php">
<b>Question?</b>
<br>
<input type="radio" name="option" value="1"> Answer 1
<br>
<input type="radio" name="option" value="2"> Answer 2
<br>
<input type="radio" name="option" value="3"> Answer 3
<br>
<input type="radio" name="option" value="4"> Answer 4
<br><br>
<input type="submit" value="Vote">
</form>

I just want to be able to chose an option, press submit and the results come up on the results.php page. It sounds so simple but from what I have been reading all day it isn't simple at all!
Can anyone help me? I am a beginner to things like this. But having learnt HTML & CSS and how to build websites, I am trying to advance myself but I need all the help I can get!
Sorry if this is in the wrong section but like I said I'm not sure what I'm doing or where it should go!
Cheers!

This post has been edited by dannyb90: Oct 17 2007, 04:23 PM
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Darin McGrew
post Oct 17 2007, 04:23 PM
Post #2


WDG Member
********

Group: Root Admin
Posts: 8,365
Joined: 4-August 06
From: Mountain View, CA
Member No.: 3



What does your results.php page do when you submit the form to it?
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
dannyb90
post Oct 17 2007, 04:29 PM
Post #3





Group: Members
Posts: 3
Joined: 17-October 07
Member No.: 4,084



Nothing at the moment, it's just blank. I don't know what to put on it to make the results show up.
I found a site that helped but that just coded a poll on it's own page with nothing else on the page. When I tried to adapt it to intergrate the poll onto my site the results didn't show up so I deleted the code on that page.

This is the tutorial I was using... http://www.ronsguide.com/php/ffpoll/

This post has been edited by dannyb90: Oct 17 2007, 04:31 PM
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
Brian Chandler
post Oct 17 2007, 10:32 PM
Post #4


Jocular coder
********

Group: Members
Posts: 2,460
Joined: 31-August 06
Member No.: 43



QUOTE
Nothing at the moment, it's just blank. I don't know what to put on it to make the results show up.


What do you mean by "the results"? Presumably not just _whatever the user entered_, because in that case they might as well print out the question page, fill it in, and hang the result on the wall. Presumably you need to collect the entries in a database system. Pretty elementary as programming goes, but you can't learn how to do it by studying the output (i.e. the results page on a working site). But you can probably find a prewritten poll application you can use - you will need PHP / MySQL or equivalent available.
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post
dannyb90
post Oct 18 2007, 05:39 AM
Post #5





Group: Members
Posts: 3
Joined: 17-October 07
Member No.: 4,084



Never mind, sorted it now. Thanks anyway!

This post has been edited by dannyb90: Oct 18 2007, 06:08 AM
User is offlinePM
Go to the top of the page
Toggle Multi-post QuotingQuote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



- Lo-Fi Version Time is now: 25th April 2024 - 11:59 PM