Tagged: ajax autoscroll
- This topic has 6 replies, 2 voices, and was last updated 5 years, 4 months ago by Anonymous.
Viewing 7 posts - 1 through 7 (of 7 total)
-
Anonymous(Private) June 18, 2019 at 12:05 pm #214300
Hi,
I use a SFP widget on my homepage at fertila.de. After submitting, a new page is opened with the results. I want users to land right on the results (especially important on mobile). I tried in the settings the Ajax scroll to custom selector. However this seems not to work in a new window.
Thanks for your help
GeorgTrevor(Private) June 18, 2019 at 12:15 pm #214307Results URL appears to be:
https://fertila.de/kinderwunschzentren/
You would need to add some Javascript to the page that, on document load, scrolls the page to the div with ID
search-filter-results-8030
.Anonymous(Private) June 18, 2019 at 12:31 pm #214313Works. However, now there is an autoscroll as well when I just enter the URL https://fertila.de/kinderwunschzentren/
Which I do not want.Trevor(Private) June 18, 2019 at 12:44 pm #214320Try this maybe:
<script> (function ( $ ) { $(document).on("ready", function(){ if (window.location.href.indexOf('kinderwunschzentren/?_') > 0) { $('html, body').animate({ scrollTop: $('#search-filter-results-8030').offset().top }, 'slow'); } }); }(jQuery)); </script>
-
AuthorPosts
Viewing 7 posts - 1 through 7 (of 7 total)