This post will show you how to create a new ASP.NET MVC 5 application using Visual Studio 2013. … [Read more...]
Improving the Authorize Attribute in ASP.NET MVC
The odd thing I've found with the AuthorizeAttribute, is how it redirects you to the sign in page, even when authenticated with a role that doesn't have access to the controller or action. As you can imagine, Joe Blogs (the basic user) might feel a tad confused, when presented with a sign in page when he's already signed in. … [Read more...]
How to Display a Message After Calling RedirectToAction in ASP.NET MVC
Have you ever wondered how to display a temporary message after redirecting to a new page in ASP.NET MVC? In this post, I will show you a simple way of displaying a success message after calling RedirectToAction. … [Read more...]
What is the Post Redirect Get Pattern?
The Post Redirect Get (PRG) pattern is used in web applications to prevent duplicate form submissions. If you are not using the PRG pattern, you might find your web application producing multiple business transactions. This is definitely something you don't want happening in e-commerce or banking applications. … [Read more...]
How to Improve the SEO of an ASP.NET MVC Website
Did you know that the default route of ASP.NET MVC will produce multiple URL's that display the same content? And as I am sure you are aware, duplicate content can cause all sorts of SEO problems. In this post, I will show you three steps to prevent duplicate content with ASP.NET MVC 5. … [Read more...]