I am creating a new Joomla template and have run into a problem with linking to external .js files.
<head>
<jdoc:include type="head" />
<link rel="stylesheet" href="<?php echo $this->baseurl ?>/templates/system/css/system.css" type="text/css" />
<link rel="stylesheet" href="<?php echo $this->baseurl ?>/templates/system/css/general.css" type="text/css" />
<link rel="stylesheet" type="text/css" href="<?php echo $this->baseurl ?>/templates/<?php echo $this->template; ?>/css/main.css">
<link rel="stylesheet" type="text/css" href="<?php echo $this->baseurl ?>/templates/<?php echo $this->template; ?>/css/FLpresentation.css">
<script src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template; ?>/js/jquery-2.1.4.js"></script>
<script src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template; ?>/js/FLpresentation.js"></script>
<script src="<?php echo $this->baseurl ?>/templates/<?php echo $this->template; ?>/js/FLajax.js"></script>
The Above code is included in the head tag and the CSS is working fine when I install my template into joomla. Everything looks how it should but all of my Jquery and Javascript code doesn't function. The only code that does is within tags on the index.php file.
Can anyone tell me what I am doing wrong? I have defined the files and folders in the templateDetails.xml and everything other than js is working fine despite me using the exact same method to link the CSS. Help me, I'm confused.