Although not tested following should work. As this is a customization I cannot offer full support, sorry
Step 1. Add required js to your site.
A. Copy "jquery.mCustomScrollbar.js" to "templates/gk_storebox/js/"
B. Open File: templates/gk_storebox/layouts/blocks/head.php
C. Add first line of code to where other js are declared. Add it before "gk.scripts.js". So it will look as below.
- Code: Select all
$this->API->addJS($this->API->URLtemplate() . '/js/jquery.mCustomScrollbar.js');
$this->API->addJS($this->API->URLtemplate() . '/js/gk.scripts.js');
Step 2. Add required css to your site.
A. Copy "jquery.mCustomScrollbar.css" to "templates/gk_storebox/css/"
B. Edit same File in Step 1 "head.php".
C. Find css declarations and add first line so it looks similar to below. Second line is from template.
- Code: Select all
$this->API->addCSS($this->API->URLtemplate() . '/css/jquery.mCustomScrollbar.css');
$this->API->addCSS($this->API->URLtemplate() . '/css/gk.stuff.css');
Step 3. Add custom js for required div, in your case in document body.
A. Find file "templates/gk_storebox/js/gk.scripts.js"
B. Add following code to right at the end.
- Code: Select all
jQuery(document).ready(function(){
jQuery('body').mCustomScrollbar();
});
Step 4. Following might not be necessary but try it if in case it doesn't work.
A. You can add below code in to overrride.css and enable css override option in template settings > advanced settings > css override "on".
- Code: Select all
body {
position: absolute;
top: 0;
left: 0;
bottom: 0;
right: 0;
overflow-y: auto;
overflow-x: hidden;
}
html {
overflow: hidden;
}
See you around...