On 26 Feb 2009, at 12:59, Heinz Strunk wrote:

>
> Hello,
>
> I need some kind of an autorization for my *_to_remote functions in my
> application. For example one of the *_to_remote function calls
> "/pages/welcome" and the page should be updated via  
> page.replace_html or
> something like that.
> The thing is that I don't want users to see that page when they type
> domain.com/pages/welcome into their browser.
> My idea was to add a custom header field which is added every time  
> when
> my applications sends an *_to_remote request.


There already is one :-) The X-Requested-With header gets set ( and  
the xhr? method in your controller will test for that for you)

Fred
>
>
> Does anyone know how I could do that? Doesn't necessarily need to be
> solved by adding a custom header field. Any suggestions are highly
> appreciated :)
> -- 
> Posted via http://www.ruby-forum.com/.
>
> >


--~--~---------~--~----~------------~-------~--~----~
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 [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to