ak314 Posted August 16, 2012 Share Posted August 16, 2012 (edited) dear all http://flesler.blogs...lscroll-10.html i used the plugin above and not work in my theme? who can help me? it seems that prestashop couldn't load the function from js file. i want to ask i have downloaded the js file from internet and i put it into prestashop/js folder and i have added the code in header.tpl <script type="text/javascript" src="js/flesler-plugins.googlecode.com/files/jquery.localscroll-1.2.7-min.js"></script> it can' t load the js file...what 's wrong? what the place shall i put the js file in or what the code i need to insert? also i have tried this <script type="text/javascript" src="{$base_dir}js/jquery.scrollTo-1.4.2-min.js"></script> it didn't work too! thank you!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Edited August 16, 2012 by ak314 (see edit history) Link to comment Share on other sites More sharing options...
haunter Posted August 16, 2012 Share Posted August 16, 2012 Do you have enabled Force compile? The <script type... is not showing in your source code or just show 404 when calling file? Link to comment Share on other sites More sharing options...
ak314 Posted August 16, 2012 Author Share Posted August 16, 2012 Yes, i have enabled . if i changed to <script type="text/javascript" src="http://flesler-plugins.googlecode.com/files/jquery.localscroll-1.2.7-min.js"></script> it seems to be work fine. but if i use <script type="text/javascript" src="js/flesler-plugins.googlecode.com/files/jquery.localscroll-1.2.7-min.js"></script> or <script type="text/javascript" src="{$base_dir}js/jquery.scrollTo-1.4.2-min.js"></script> it would be fail....could you tell me the reason?? thank you! Link to comment Share on other sites More sharing options...
Norwegian Rat Posted August 16, 2012 Share Posted August 16, 2012 Have you tried putting the .js file in the theme's js dir? And is it a cms page you want this scrolling to appear? Had a similar problem not long ago, and I experienced that instead of putting the script call(s) in the header.tpl, I put it in the cms.tpl, and everything worked fine. So if you give this a go: <script type="text/javascript" src="{$js_dir}jquery.scrollTo-1.4.2-min.js"></script> in either header.tpl, or cms.tpl if it's a cms page. (if it's the header.tpl make sure you insert the script below the {$HOOK_HEADER} around line 60. Link to comment Share on other sites More sharing options...
Norwegian Rat Posted August 16, 2012 Share Posted August 16, 2012 If it still won't work you can, for good measure, try adding the script in it's whole code to the .tpl and see if that helps. I guess it's not the best thing to do since the code is a bit long, but you know.....when debugging..... =) Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now