I want to put some icons in a web and I want to know how can I detect if a person has a gravatar so in case they don''t have one I want to show another icon, can anyone help me?? Thanks in advance Belén --~--~---------~--~----~------------~-------~--~----~ 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@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
I tried a while ago to implement this and finished doing a column in the users table saying wants_gravatar:boolean. If it was true, then the user.face method would return their gravatar picture like so: if wants_gravatar? "http://www.gravatar.com/avatar.php? gravatar_id=#{Digest::MD5.hexdigest(email_address)}" else self.avatar ? self.avatar.public_filename : DEFAULTFACE end but actually checking wether the email address mapped any pictures in gravatar or not, i could not find a way. I decided that if the user wanted a gravatar an didnt have one, hed just get the gravatar logo. it was so much less painfull to implement. It still appreciate if anyone knew how to perform the check. j On Jul 7, 12:00 pm, Belén <bllam...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> I want to put some icons in a web and I want to know how can I detect > if a person has a gravatar so in case they don''t have one I want to > show another icon, can anyone help me?? > Thanks in advance > Belén--~--~---------~--~----~------------~-------~--~----~ 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@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---
seems there are two plugins available: http://en.gravatar.com/site/implement/rails but none of them seems to implement any check, if a gravatar exists as far as I can see, the only thing possible is to set one of three default images: http://en.gravatar.com/site/implement/url --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---