As a learning exercise, I've created a blank MVC4 Application and I'm building a blog-type website with it.
I'm learning that this probably wasn't the best idea... I've copied the Content
and Views\Shared
folders into my blog project from another one I created with the default stuff, but the following lines are giving me errors:
@Styles.Render("~/Content/css")
@Scripts.Render("~/bundles/modernizr")
Both underlined red in my _Layout.cshtml file, the error is:
The name does not exist in the current context
So I went back to my "default" project and checked where those come from by hovering over them. The tooltip said
class System.Web.Optimization.Styles
class System.Web.Optimization.Scripts
So I went through and installed the Web Optimization Framework as per this question but it hasn't fixed the problem.
The project builds n all, but no styles are applied and I'm 100% sure anything that the script controls isn't working either...
Can anyone help me fix this?