Page 1 of 1
Custome scrollbar [SOLVED]
Posted: Wed Jul 20, 2011 10:20 pm
by Sign
Hi All,
I wondering if anyone has experience is creating a custom scrollbar (text area) in CMSMS. I have tried a couple of things with out success. Could some help me out, please
Re: Custome scrollbar
Posted: Thu Jul 21, 2011 4:06 am
by frankmanl
Hey Sign,
I took the script of jScrollPane from
http://www.net-kit.com/jquery-custom-scrollbar-plugins/.
This is how I installed it:
1) I put all files of the script in directory
/uploads/scripts/jScrollPane/
2) I then made a Global Content Block
jscrollpane containing all calls to stylesheets, scripts etc.
Code: Select all
<!-- styles needed by jScrollPane -->
<link type="text/css" href="/uploads/scripts/jScrollPane/style/jquery.jscrollpane.css" rel="stylesheet" media="all" />
<!-- latest jQuery direct from google's CDN -->
<__script__ type="text/javascript" src="http://ajax.googleapis.com/ajax/libs/jquery/1.4/jquery.min.js"></__script>
<!-- the mousewheel plugin -->
<__script__ type="text/javascript" src="/uploads/scripts/jScrollPane/script/jquery.mousewheel.js"></__script>
<!-- the jScrollPane script -->
<__script__ type="text/javascript" src="/uploads/scripts/jScrollPane/script/jquery.jscrollpane.min.js"></__script>
{literal}
<__script__ type="text/javascript" src="/uploads/scripts/jScrollPane/script/jqery.jscrollpane.js"></__script>
<__script__ type="text/javascript" id="sourcecode">
$(function()
{$('.scroll-pane').jScrollPane();});
</__script>
{/literal}
3) In my template I put the tag for the GCB: {global_content name='jscrollpane'}
And of course I adjusted the CSS to my whishes.
Frank
Re: Custome scrollbar
Posted: Thu Jul 21, 2011 6:22 am
by Sign
Hi Frank,
Thank you for your fast response. This is what i was searching for.