Supporting each other

Community forums

Welcome, Guest
Username: Password: Remember me
The place for more technical questions for those who want to create new pagetypes or bespoke functionality.
  • Page:
  • 1

TOPIC: Scroll function

Scroll function 3 years 9 months ago #4330

  • Neil Pollock
  • Neil Pollock's Avatar Topic Author
  • Offline
  • Senior Boarder
  • Senior Boarder
  • Posts: 77
  • Thank you received: 3
I'm trying to use the jQuery scroll function in a XOT project, but for some reason it doesn't want to work. As a test I've added this, but the console logs nothing:
$(window).scroll(function(){
  console.log("scrolling");
});

Any ideas why this would be?

Please Log in or Create an account to join the conversation.

Scroll function 3 years 9 months ago #4331

  • jjs
  • jjs's Avatar
  • Offline
  • Moderator
  • Moderator
  • Posts: 379
  • Thank you received: 63
Hi Neil,

It's not the window that is scrolling but the x_pageHolder panel when pages scroll. Try this:

$('#x_pageHolder').scroll(function(){
  console.log("scrolling");
});

John

Please Log in or Create an account to join the conversation.

Last edit: by jjs.
  • Page:
  • 1
Moderators: jjs
Time to create page: 0.040 seconds
Copyright © 2020 The Xerte Project.
Xerte logo Apereo logo OSI Logo

Search