Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
I have a surface controller and need todo some custom routing so i have:
[RoutePrefix("api/people")] public class ProfileImageController : SurfaceController { [Route("GetImage/{hrID}")] public FileResult Get(int hrID)
i would expect the following to work /api/people/GetImage/12334
However i get 404.
I have component where i have
GlobalConfiguration.Configuration.MapHttpAttributeRoutes();
So it should work? Unless my url is incorrect?
Anyone any ideas?
Ok i was missing:
RouteTable.Routes.MapMvcAttributeRoutes();
that fixed it
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.
Continue discussion
custom routing for surface controller in v8
I have a surface controller and need todo some custom routing so i have:
i would expect the following to work /api/people/GetImage/12334
However i get 404.
I have component where i have
So it should work? Unless my url is incorrect?
Anyone any ideas?
Ok i was missing:
that fixed it
is working on a reply...
This forum is in read-only mode while we transition to the new forum.
You can continue this topic on the new forum by tapping the "Continue discussion" link below.