Sparksido Sparksido - 1 year ago 60
jQuery Question

Javascript is not responding

I have an HTML page referencing a jQuery page which just console logs

hello there
, but the code in the jQuery page is not doing anything and I don't know why.

<!DOCTYPE html>
<link rel='stylesheet' href='/stylesheets/style.css' />
<p>hello there you idiot</p>
<script type="text/javascript" src="javascripts/jquery/jquery-2.2.4.min.js"></script>
<script type="text/javascript>" src="javascripts/testscript.js"></script>

//alert("hello there");
console.log("hello there");
document.write("hello there");

Can anyone please tell me why the script is not console loging anything. Thank you

Answer Source

Probably, because you're including the file wrong way (you have a typo).

The right way should be:

<script type="text/javascript" src="javascripts/testscript.js"></script>