It's better if you download jquery into your own space and load it from there, rather than retrieving it from jquery.com.
Within the script tags you need to wrap the jquery code inside a ready function so that it doesn't get run until the DOM is ready and scripts have loaded. So try ... <script type="text/javascript"> jQuery(function($){ //shorthand version of jQuery(document).ready(function($){ $("a").click(function(){ $(this).hide("slow"); return false; }); }); </script> Shishir Srivastava wrote: > > > Hi All, > Just started working on jQuery. Here's my simple piece of code > borrowed from the tutorials section of jQuery page. > > <html> > <head> > <script type="text/javascript" src="http://jquery.com/src/ > jquery.js"></script> > <script type="text/javascript"> > $("a").click(function(){ > $(this).hide("slow"); > return false; > }); > </script> > </head> > <body> > http://jquery.com/ jQuery > </body> > </html> > > Now when I open this html file in either firefox, or IE , it doesn't > do what it's supposed to, i.e. slowly hide the link and remain on the > same page, but instead it open the specified link page. > > Can anyone please verify what's wrong here. > > Thanks, > Shishir > > > -- View this message in context: http://www.nabble.com/jQuery-script-not-working.-tf4411573s15494.html#a12588835 Sent from the JQuery mailing list archive at Nabble.com.