jQuery Cycle Plugin not working in ASP.NET MVC 4 -


i created asp .net mvc4 project default , put code this sample , not working @ all.

any clues?

error:

uncaught referenceerror: jquery not defined jquery.cycle.all.latest.js:918 uncaught referenceerror: $ not defined

<!doctype html> <html lang="en"> <head>     <meta charset="utf-8" />     <title>@viewbag.title - asp.net mvc application</title>     <link href="~/favicon.ico" rel="shortcut icon" type="image/x-icon" />     <meta name="viewport" content="width=device-width" />     @styles.render("~/content/css")     @scripts.render("~/bundles/modernizr")      <style type="text/css">         .slideshow {             height: 232px;             width: 232px;             margin: auto;         }              .slideshow img {                 padding: 15px;                 border: 1px solid #ccc;                 background-color: #eee;             }     </style>      <script type="text/javascript" src="http://cloud.github.com/downloads/malsup/cycle/jquery.cycle.all.latest.js"></script>      <script type="text/javascript">         $(document).ready(function () {             $('.slideshow').cycle({                 fx: 'fade' // choose transition type, ex: fade, scrollup, shuffle, etc...             });         });     </script>  </head> <body>     <header>         <div class="content-wrapper">             <div class="float-left">                 <p class="site-title">@html.actionlink("your logo here", "index", "home")</p>             </div>             <div class="float-right">                 <section id="login">                     @html.partial("_loginpartial")                 </section>                 <nav>                     <ul id="menu">                         <li>@html.actionlink("home", "index", "home")</li>                         <li>@html.actionlink("about", "about", "home")</li>                         <li>@html.actionlink("contact", "contact", "home")</li>                     </ul>                 </nav>             </div>         </div>     </header>     <div id="body">         @rendersection("featured", required: false)         <section class="content-wrapper main-content clear-fix">             @renderbody()         </section>     </div>     <footer>         <div class="content-wrapper">             <div class="float-left">                 <p>&copy; @datetime.now.year - asp.net mvc application</p>             </div>         </div>     </footer>  </body> </html> 

it doesn't include jquery library. need add <head> section:

<!-- include jquery library --> <script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.5/jquery.min.js"></script> 

Comments

Popular posts from this blog

Why does Ruby on Rails generate add a blank line to the end of a file? -

keyboard - Smiles and long press feature in Android -

node.js - Bad Request - node js ajax post -