c# - How do I use an Ajax.ActionLink without updating the URL -


i got following ajax actionlink in cshtml page:

@ajax.actionlink("sort date",                 "specific",                 "events",                 new ajaxoptions {                     updatetargetid="eventlistcontainer",                     insertionmode=insertionmode.insertafter,                     httpmethod="get"                 }) 

and got these 2 methods in controller:

public actionresult overview(string user) {     // return partialview here } 

and

public partialviewresult specific() {     // return partialview here } 

with following route:

routes.maproute(   name: "eventsroute",   url: "events/{user}",   defaults: new { controller = "events", action = "overview" } ); 

now, every time call ajax method, overview gets called, specific passed inside, instead of specific method. how can make sure specific() gets called, without updating url?

something this. play around ordering.

routes.maproute(   name: "eventsspecificroute",   url: "events/specific",   defaults: new { controller = "events", action = "specific" } ); 

Comments

Popular posts from this blog

linux - xterm copying to CLIPBOARD using copy-selection causes automatic updating of CLIPBOARD upon mouse selection -

c++ - qgraphicsview horizontal scrolling always has a vertical delta -