This is what I did. I created a folder to store a html file and an external jquery file.
Then the code for importing the jquery file is written like this
<script type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.7.2/jquery.min.js"></script> <script type="text/javascript" src=script.js"></script> //script is the name of the jquery file
//the code within the jquery file is this
$(document).ready(function(){$('p').css("background-color", "#d0e4fe");});
However, it won't work and nothing happens. It only works when I embed the code within the html. Just wonder why and what I did wrong?

New Topic/Question
Reply



MultiQuote




|