<title>This is my Sample Page</title>
<link rel=“stylesheet” type=“text/css” href=“main1.css” />
thanks for the response. Two quick follow-up questions: (1) so should I remove the $(document).ready entirely? and (2) should I also put the link to jQuery down near the bottom before the closing body tag as well - e.g., <script src=“https://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js”></script> Thanks!
It isn’t needed, but I don’t think it does any harm, either. 'Sup to you.
should I also put the link to jQuery down near the bottom before the closing body tag as well
Having it there would slow the script running in those browsers that can’t detect when the HTML has loaded and which therefore have to wait for the load event to be triggered instead. So if there are lots of images in the page and you have a significant number of visitors using old browsers then getting rid of it might speed things up a bit.
Yes, I’ve also seen problems with jQuery not working, which seemed to be caused by linking to jQuery in the head and having scripts at the bottom of the page. Moving the library to the bottom of the page fixed the problem, so I can only assume that was the problem.