javascript runtime error '$' is undefined -


i facing "javascript runtime error '$' undefined" error on asp.net project in visual studio 2010. have tried many solutions given here not succeed. code is

    <!doctype html public "-//w3c//dtd xhtml 1.0 transitional//en" "http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head><link rel="shortcut icon" href="../../favicon.ico" /><title>     website </title>     <script type="text/javascript" src="../javascript/jquery-1.3.2.min.js"></script>     <script type="text/javascript" language ="javascript">         function mainmenu() {             $(" #nav ul ").css({ display: "none" });              $(" #nav li").hover(function () {                 $(this).find('ul:first').css({ visibility: "visible", display: "none" }).show(400);             }             , function () {                 $(this).find('ul:first').css({ visibility: "hidden" });             });         }    $(document).ready(function () {         mainmenu();     }); </s 

& error message indicates last 2 lines.

can me please? how can solve this?

your src not valid path, jquery not loading , cannot use undefined.

1) check path correct one, whether using jquery file locally on machine.

2) please note, tag in not closed properly:

  <!doctype html public "-//w3c//dtd xhtml 1.0 transitional//en" "http://www.w3.org/tr/xhtml1/dtd/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head><link rel="shortcut icon" href="../../favicon.ico" /><title>     website </title>     <script type="text/javascript" src="../javascript/jquery-1.3.2.min.js"></script>     <script type="text/javascript" language ="javascript">         function mainmenu() {             $(" #nav ul ").css({ display: "none" });              $(" #nav li").hover(function () {                 $(this).find('ul:first').css({ visibility: "visible", display: "none" }).show(400);             }             , function () {                 $(this).find('ul:first').css({ visibility: "hidden" });             });         }    $(document).ready(function () {         mainmenu();     });  </script> 

Comments

Popular posts from this blog

dns - How To Use Custom Nameserver On Free Cloudflare? -

python - Pygame screen.blit not working -

c# - Web API response xml language -