Call a view with ajax inside jquery file
I have a jquery file from which I'd like to call a view. The action at the controller is called Inbox. What i开发者_JS百科s the right way to call this action from the jquery file?
Your question is very vague and strangely formulated, but i suppose you're looking for jquery assistance.
jQuery offers many ways to do an ajax call. The easiest one is load() $('#container').load('path/to/file.html');
when calling an ajax, your data must be a json object
$.ajax({
type: "get",
url: "planning/inbox",
data: { s.Site: searchSite, s.Date: SearchDate }
})
精彩评论