Ruby on Rails: link_to_remote and rel
Posted
by DerNalia
on Stack Overflow
See other posts from Stack Overflow
or by DerNalia
Published on 2010-06-15T18:38:43Z
Indexed on
2010/06/15
18:42 UTC
Read the original article
Hit count: 289
ruby-on-rails
I want a link to remote to have a rel tag, because I want to use facebox with it.
I had it working with a regular link to... but I needed the link to remote to handle the event that a user doesn't have javascript enabled.
this, currently does't work (except for the non-javascript part )
<%= link_to_remote "Ask a Question",
{:url =>
{:action => :ask_question,
:id => @container.id.to_s,
:javascript_disabled => false
}, :rel => 'facebox'},
:href => url_for(
:controller => :view,
:action => :ask_question,
:id => @container.id.to_s,
:javascript_disabled => true) %>
© Stack Overflow or respective owner