asp.net mvc razor: How to directly access .cshtml page? -


how can directly access .cshtml file in asp.net mvc using razor view engine?

for example have url: localhost/home/about. load site inside "master" page.

i want load page without loading master page. thinking use url: localhost/home/about.cshtml. it's not working.

how can load view page without loading master page?

you can use method html.partial this:

@html.partial("about")

edit

i might have missunderstood question. if want avoid including master page need remove layout.

add top of view:

@{      layout = null;  } 

Comments

Popular posts from this blog

python - Scipy curvefit RuntimeError:Optimal parameters not found: Number of calls to function has reached maxfev = 1000 -

c# - How to add a new treeview at the selected node? -

java - netbeans "Please wait - classpath scanning in progress..." -