Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Voting Poll

Status
Not open for further replies.

fparty

Programmer
Nov 17, 2011
9
GB
I have a voting poll and 5 options for yes no or abstain.

db is simple for now, 5 rows each with fields

id, choice1=yes, choice2=no, choice3=abstain and vote1 vote2 vote3
catching the counts for each.

I want to user only have one for for each row.. lets say each topic is

topic1, topic2.. etc to topic5

I can catch LOCAL_ADDR coming in but i need to validate if they have voted already on each topic..

i have so far...

<code>
If LOCAL_ADDR <> Session("LOCAL_ADDR") then
rsPoll.Fields("votes" & iVote).Value = rsPoll.Fields("votes" & iVote).Value + 1
rsPoll.Update
' Set Flag to prevent revoting
Session("LOCAL_ADDR") = LOCAL_ADDR
End If
</code>

 
internet or intranet?

identifiable users or anonymous?



Chris.

Indifference will be the downfall of mankind, but who cares?
Time flies like an arrow, however, fruit flies like a banana.
Webmaster Forum
 
Internet, any user, ive thought of updating db with ip and id of poll?
 
IPs do not necessarily identify individual users why not just set a cookie on the machine?

Chris.

Indifference will be the downfall of mankind, but who cares?
Time flies like an arrow, however, fruit flies like a banana.
Webmaster Forum
 
Third party cookies maybe, but the vast majority of people and PC's have cookies enabled.

Online shopping needs cookies.
Webmail needs cookies.

There maybe some tribe living in the mountaineous jungle region of Indonesia that don't accept cookies but the majority of people know that cookies are actually harmless and are not likely leap out of the USB ports and strangle them while they sleep.

Chris.

Indifference will be the downfall of mankind, but who cares?
Time flies like an arrow, however, fruit flies like a banana.
Webmaster Forum
 
Can u give us cookie example never used em
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top