Accessing rails private/protected methods through javascript or jquery
I know I can access pu开发者_StackOverflow社区blic controller actions by doing something like this with jquery:
$("#stuff").load("/controller/action");
But how do I access the private/protected actions in a controller using jquery or javascript?
You can create an action in the controller file which will call your private or protected action. A direct call is not possible.
精彩评论