Tech
Forums
Jobs
Books
Events
Videos
Live
More
Interviews
Certification
Training
Career
Members
News
Blogs
Contribute
An Article
A Blog
A Video
An Ebook
An Interview Question
Register
Login
3
Answers
ASP.Net MVC Core: setup view area location path
tri_inn
7y
352
1
Reply
i read a article which discuss how to setup custom path for view
http://www.c-sharpcorner.com/article/expanding-razor-view-location-and-sub-areas-in-asp-net-core/
one area is not clear regarding routing code setup.
app.UseMvc(routes =>
{
routes.MapRoute(
name:
"subAreaRoute"
,
template
:
"{area:exists}/{subarea:exists}/{controller=Home}/{action=Index}/{id?}"
);
routes.MapRoute(
name:
"areaRoute"
,
template
:
"{area:exists}/{controller=Home}/{action=Index}/{id?}"
);
routes.MapRoute(
name:
"default"
,
template
:
"{controller=Home}/{action=Index}/{id?}"
);
});
what is the meaning of
{area:exists}
code ?
what it does ? what it is checking ?
please help me to understand this. thanks
Post
Reset
Cancel
Answers (
3
)
Next Recommended Forum
how to show mutiple views in sam page using mvc sitemap
facing problem in navigation