[Facebooker-talk] view problem

Mike Mangino mmangino at elevatedrails.com
Fri Jan 23 17:26:40 EST 2009


user.location is returning an object, so when to_s is called you get  
the inspect string, like #<Location 34327832>

user.location.city should print the string.

Mike

On Jan 23, 2009, at 4:36 PM, kevin lochner wrote:

> i'm trying to print out user locations in my view.  I'd like to just  
> pass a user model to the
> view and print out the user location as user.location.city
>
> I can access user.location.city in the controller, but in the view  
> user.location returns  "#"
>
> Could someone explain what's going on and maybe give an alternative  
> solution?
>
> _______________________________________________
> Facebooker-talk mailing list
> Facebooker-talk at rubyforge.org
> http://rubyforge.org/mailman/listinfo/facebooker-talk

--
Mike Mangino
http://www.elevatedrails.com





More information about the Facebooker-talk mailing list