RedirectToRoute from module to Orchard Home

Topics: Writing modules
Aug 9, 2011 at 11:18 PM

I'm sure this is really simple, but it seems to be escaping me at the moment...

In a controller for my module, how would I construct a RedirectToRoute() that simply takes me back to the Home page of the site? I tried using controller = "home" and action = "index", but I think I need the area parameter and I'm not sure what it would be. Thanks.

Aug 9, 2011 at 11:56 PM

Did you try Orchard.Core?

Aug 10, 2011 at 12:02 AM

Yep...that didn't work either. I can actually just do it with

return new RedirectResult("~/");
I don't need to specify and route parameters anyways. Thanks.

Aug 10, 2011 at 12:03 AM

Yes, that would work :)