Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

71 lines (52 sloc) 2.864 kb
note : this extension originally is a fork of .
but the old one is need some more functionality so i fork it from sensorario(
scrollTo ' s default behavior is scroll to the top of the document , but you can also set an html tag 's id ,this is
why this extension is named scrollTo but scrollTop .
if you need scroll from some link element to top please check out the original version :
how to use it
first check out this extension and put it to your protected/extensions dir
or some orther dir, then just use the path alias to refer it , i don't know you will put it to
where but just use path alias of this widget . for me i just put it to my costumized dir .
if you put it to extension dir , you can change the following path alias 'common.widgets.KScrollToWidget'
to 'ext.KScrollToWidget' or 'ext.KScrollToWidget.KScrollToWidget' , just depends on your situation , if you don't
understand how to use the path alias please refer to
or some wiki , forum topics
in your view file :
<div style="height:600px">
click the following there button to see the effects
<div id='dest' > the left widget will scroll to here </div>
<div style="height:1200px">
click the following there button to see the effects
// echo str_repeat('<br/>',65)."\n";
'label' => 'Go on top',
'speed' => 'slow',
'background-color'=> '#78901f',
'label' => 'toTop2',
'speed' => 2000,
'position'=> 'center',
'dest'=> 100,
// 'background-color'=> '#446477'
)); ?>
'label' => 'scroll to the dest div',
'speed' => 200,
'destination' => 'dest' ,
'position'=> 'left',
'background-color'=> '#f26077'
)); ?>
Jump to Line
Something went wrong with that request. Please try again.