On Mar 11, 2007, at 2:12 AM, vin wrote:
>
> I am trying to buld a link with text displayed within a text_field or
> text_field_tag. e.g. the following text field displays an ID of 1.
>
> <%= text_field_tag(@contact, @contact.id , {:readonly => true})
%>
>
> I would like the 1 to also be a hyper link to allow me open and show
> contact.
>
> Effectively I am trying to do something like
>
> <%= text_field_tag(@contact, <%= link_to @contact.id, :action
=>
> ''show_contact'', :id => @contact.id %> , {:readonly
=> true}) %>
I don''t think you can do that. Browsers "strip" most markup
from text
field contents.
-- fxn
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---