#8, I get a reference error saying, "Did you put 'div' inside $() ?"


#1

I am having a problem with the Electr(on)ic Slide exercise, even when I put slow in quotes as well. This is what I wrote, but it made a reference error saying, "Did you put 'div' inside $() ?"

<!DOCTYPE html>
<html>
<head>
<title></title>
<!--Add your script tag here.-->
<script type="text/javascript" src="script.js">
$(document).ready(function() {
$('div').slideDown('slow');
});
</script>
</head>
<body>
<div></div>
</body>
</html>

Why won't this work?


#2

Hi William,

Your JavaScript/jQuery code needs to go in the script.js file, not inside your <script> tags.


#3

Ok, I will do that, I didn't see the JS tab. Thanks a lot :slight_smile:


#4

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.