Friday, August 5, 2011

[Rails] Re: Escape pound key in url with globbing

On Aug 5, 12:45 pm, Karen <karensc...@googlemail.com> wrote:
> Hey everyone,
>
> I am using the routes globbing in rails 3.0.9
> There when I add at any url a *anything at the end, the rest of the
> url should be contained in the params[:anything] filed.
>
> some_url_route/*anything
>
> This is true and also works for most of the special characters like $,
> ^, @ ect...
> However, it is not working for the pound key '#'
> The string simply stops at this symbol.
> I can escape this by escaping the # with %23.
> However, this is not what I want. I really want users to be able to
> put the # key into the string!
> Does anyone know if this behaviour of rails is on purpose and if there
> is any other workaround
> other than using %23??
>

This isn't really a rails thing. The bit after the # is known as the
fragment and isn't sent by the browser to the server at all

Fred

--
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@googlegroups.com.
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.

0 Comments:

Post a Comment

Subscribe to Post Comments [Atom]

<< Home


Real Estate