On 12/30/07, Jables <brun3797-Meo6Lv8EUjg3uPMLIKxrzw@public.gmane.org>
wrote:>
> Hey guys,
> I''m hoping someone can help me with a strategy to implement the
> following: I have a voting system with a models/tables for votes,
> links, and users. In the view I want to go through the collection of
> links and for each one check to see if a user has voted on it. All
> the details of displaying the links are implemented, what I am trying
> to figure out the best way to take each link and ask - has the current
> logged in user voted for this? Any help with an implementation would
> be much appreciated it.
Have you considered storing the user id with the vote? You can then
validate your list against the user''s current session id or whatever.
--
Greg Donald
http://destiney.com/
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Ruby on Rails: Talk" group.
To post to this group, send email to
rubyonrails-talk-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
To unsubscribe from this group, send email to
rubyonrails-talk-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---