Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [routing]

For questions related to the creation of custom or use of default routes in Sitecore, covering routing for MVC and WebAPI, in addition to ReactJS routing, etc.

0
votes
0answers
38 views

Why do my custom routes not work in Sitecore 9? [on hold]

Trying to apply custom routing in Sitecore 9 using following documentation: https://doc.sitecore.net/sitecore_experience_platform/developing/developing_with_sitecore/mvc/use_mvc_routing. But no luck, ...
1
vote
1answer
45 views

JSS LayoutService decoupled from Routing in Angular

Is it possible to decouple the use of the LayoutService from all of the Routing code and use it independently? We are upgrading an AngularJS application to Angular and have incorporated JSS but are ...
1
vote
1answer
30 views

Requested document not found when using MVC routes

I am getting 404s (requested document not found) when I try to use a custom route I created per the guide here: https://kb.sitecore.net/articles/700677. My patch config is showing up in showconfig, ...
0
votes
1answer
778 views

Sitecore WebApi custom route not working controller not found

Controller: public class ExampleController : Controller { private readonly ISitecoreContext _sitecoreContext; public ExampleController () { } [System.Web.Http.HttpGet] ...
7
votes
2answers
669 views

A route named x is already in the route collection. Route names must be unique

EXM is throwing error when I go to the dashboard. I see the following error in the Sitecore log file. Exception System.ArgumentException: A route named 'CountriesV1' is already in the route ...
2
votes
1answer
267 views

Sitecore MVC Routing and Virtual Folders

I have a multi-site Sitecore instance with several sites defined using the physicalFolder/virtualFolder attributes defined on the <site> nodes all done with MVC. There is some functionality I ...
4
votes
3answers
1k views

ServiceApiController Method not found when using HttpPost and ComplexType (Sitecore 8.1.3)

I am working on refactoring some code and want to create WebApi services to do so. I have created an initialization pipeline that registers custom routes. I am still able to follow base sitecore ssc ...
3
votes
1answer
618 views

How to have a custom url for a listing page

I am unable to figure out the correct route configuration for this scenario. The tree structure is as: Home |_Articles |_Topic1 |_Blogs |_blog1 |_blog2 |_Topic2 Each topic ...
0
votes
2answers
295 views

I need to integrate a controller from a compiled dll into a controller I can build/control. How can I call that as a rendering?

I'm able to call this compiled dll's controller directly in a Sitecore rendering - e.g. I can create a rendering where I reference the controller, controller action, and area and the content from the ...
4
votes
2answers
185 views

EntityService-based controllers stop working when adding a controller with a named route

ASP.NET Web API 2 allows to set route name on a controller: Route names are useful for generating links, so that you can include a link in an HTTP response. I define two controllers, each of them ...
4
votes
2answers
263 views

Redirect requests based on missing data on wildcard item

I have a URL, myWebsite.com/locations, and currently if you go to myWebsite.com/locations/{any valid ID} you get a page with content about the location. However, if you go to myWebsite.com/locations/...
5
votes
2answers
475 views

How do I remove /sitecore from API calls?

A client I'm working with has an internal API built that they use for search purposes, now API URLs are being built like this: website/internal-api/sitecore/controller/method My Question is if there ...
4
votes
1answer
44 views

wo url serving default.aspx

i've setup various rewrite rules within sitecore using the url rewrite module. for some really bizarre reason /wo refuses to work, and browsing to /wo on other Sitecore sites I've worked on appears to ...
6
votes
1answer
414 views

How to pass dynamic parameters to a Sitecore page via the URI?

On our website we have a page which is accessible via a path like: www.example.com/statistics We would like this page to show different content based on the URI, e.g. www.example.com/statistics/...
2
votes
1answer
236 views

Html.Sitecore().Controller on a CD - No route in the route table matches the supplied values

I am having a similar problem to InvalidOperationException: No route in the route table matches the supplied values That is, I am getting the error: No route in the route table matches the ...
0
votes
1answer
256 views

MVC Routing with Language Variant in Sitecore

I have MVC Routing issue in Sitecore. I have the following route in myRegisterRoutes() method. For this method I need to add language variant since I have enabled language fallback. Could some please ...
5
votes
0answers
558 views

How to ignore routes from specific dlls in Sitecore 8.2 [closed]

Sitecore 8.2 update 1. I have added few dll refences in project. The DLLs are from external application and have their own webapi controllers and routes. I am using Autofac and excluding the ...
9
votes
1answer
3k views

InvalidOperationException: No route in the route table matches the supplied values

I've recently deployed a SC 8.1 update 3 site to production (seperate CM and CD) and on the CD side I'm getting this error: Server Error in '/' Application. No route in the route table matches the ...
3
votes
0answers
410 views

Custom route for MVC controller in a market place package is not working

I am working on a marketplace package that services some analytics data via MVC controllers. But when testing I am finding several implementations of DI that cause my route to fail on the site. One ...
7
votes
2answers
1k views

Error when using custom routes with https: “Attempt to retrieve context object of type 'Sitecore.Mvc.Presentation.RenderingContext' from empty stack.”

We have a login/register modal that is being called via javascript on the front end. I created a custom route to point to the right action controller, and it works fine in every environment - except ...
5
votes
4answers
3k views

Passing a parameter to controller rendering through URL

I have a component on my page that is a controller rendering and I'd like to pass a parameter in through the URL, but not as a query string parameter. So, instead of site.com/product?id=123, I want: ...