Suresh Pattu
Suresh Pattu

Reputation: 6219

Scroll to Content | Kendo UI Mobile

I have tried here myjsfiddle
I am trying to show login section when user clicks any link on the home page. I will show the home page again when user clicks on logo which is there in the header.
The problem is if the scroll down on the home page and click any link then the in the login section also scroll downed I want to scroll to the top of the login section How to do that here.
Script is here :

var kendoMobileApplication = 
    new kendo.mobile.Application($(document.body),{ skin: 'flat' });



$('.homePage-nav-menu-list >li>a').click(function(){
    $('.homePage-nav-menu-list').hide();
    $('.loginSec').show();
});

$('.logoImg').click(function(){
    $('.homePage-nav-menu-list').show();
    $('.loginSec').hide();
});

Upvotes: 1

Views: 1649

Answers (1)

Omar
Omar

Reputation: 31732

You need to use reset() method on scroller().

var app = new kendo.mobile.Application();
app.scroller().reset();

Reference: http://docs.telerik.com/kendo-ui/api/mobile/application#methods-scroller

Demo

Upvotes: 1

Related Questions