Search code examples
jqueryhyperlinksubdomainexternal

external javascript not working on subdomain


I'm working on a dev site using isotope on a subdomain and ran into an issue where the javascript isn't working (previews fine in Dreamweaver Live mode), so I created two simple test pages to see what the issue is.

Internal jQuery working: http://stanley.4pixels.co.uk/index2.html

External jQuery not working http://stanley.4pixels.co.uk/index3.html

I thought it might be a path issue on the subdomain, but the CSS file works fine on both. I can't honestly see where the problem lies and I'm not new to building websites... only this server (WHM cPanel), so maybe it's something there?


Solution

  • test.js is just one line of comment... it does nothing.

    It looks like this:

    // JavaScript Document$(document).ready(function(){ "use strict";  $("button").click(function(){    $(".box").slideToggle();  });});
    

    No new line between comment and real code.