A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/alvarotrigo/fullPage.js/issues/4628 below:

Loading fullPage.js in an iframe forces scroll of parent window · Issue #4628 · alvarotrigo/fullPage.js · GitHub

Description

When loading fullPage.js inside an iframe, unless the option scrollBar: true is used, fullPage.js forces the parent window to scroll to the loaded iframe.

Link to isolated reproduction with no external CSS / JS

https://codepen.io/alvarotrigo/pen/OJYvRXv

It won't work on Codepen, but you can copy the code and run a separate page to reproduce it.
Make sure both pages run in the same domain. I suspect it only works when the iframe and the parent are both the same domain.

Steps to reproduce it
  1. Copy the content of this codepen in a page in local
  2. Make sure to have a local version of a page using fullPage.js
  3. Replace the src for the iframe with the local fulllPage.js page.
  4. Load the page
  5. It will scroll to the dynamically loaded iframe
Versions

Safari, Firefox, Chrome...
fullPage.js 4.0.21 and probably some other previous versions


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4