Thursday, 15 January 2015

jquery - Adding styles to mvc application -



jquery - Adding styles to mvc application -

i'm new asp/mvc programming. want add together styles jquit , a jquery-ui-themeroller. tried copy-pasting script , css files , refer them in cshtml file. but, views not rendering. i'm doing wrong. how can styles work?

thank you

i created new application using net template of mvc4. downloaded jmetro template 1 of above sites. pasted contents "../../content/jquery-ui.css" , "../../scripts/jquery-ui-1.8.16.custom.min.js" folders, which, included in registration.cshtml file.

use section in view i.e.

@section myscript{ <script type="text/javascript" src='path'/> }

and in _layout.cshtml page, render section on area using:

<head> @rendersection("myscript", false) </head>

hope helps.

jquery css asp.net-mvc jquery-ui

No comments:

Post a Comment