HTML Academy
  • HTML Academy
  • Courses
  • Tutorials
  • Courses
  • Tutorials
  • Sign up
  • Log in
  • Home
  • Interactive courses
  • JavaScript basics
  1. Conditions and creating elements 0/15
  2. Element collections and properties 0/16
  3. Scrolling and operators 0/14
  4. Dynamic element styles 0/16

Chapter 3: Scrolling and operators

13 tasks, 1 challenge, 1 summary

We will learn how to control scrolling in the browser, and we will also find out more about equality operators and the logical operator AND. We will program a button that will return the use to the top of the page and create filtering for the news site.

Start
1. The onscroll event handler Task
2. The pageYOffset property Task
3. Show the “Up” button Task
4. The scrollTo method Task
5. Scroll page on click Task
6. Finish working on the “Up” button Task
7. Start filtering on the site Task
8. Strict equality operator Task
9. The onchange event handler Task
10. Add a class to news story from the selected category Task
11. Strict inequality operator Task
12. Showing news from a selected category Task
13. The logical operator AND Task
14. Summary of “Scrolling and operators” Summary
15. Test: Rate the site Challenge

Cookies ∙ Privacy ∙ License Agreement ∙ About ∙ Contacts ∙ © HTML Academy OÜ, 2019−2025

VISAMastercard

Log in

or

Forgot your password?

Sign up

Sign up

or
Log in

Restore access

Have you forgotten your password or lost access to your profile? Enter your email connected to your profile and we will send you a link to restore access.

Forgot to connect your email to the profile? Email us and we’ll help.

We are using cookies to gather information which will help you use our website most effectively. You can read about this here or disable this feature if you want. By continuing to browse the site, you agree to our use of cookies.