Hello, implemented AJAX loading landing pages when scrolling. Implemented loading section by section. Sections are successfully queried alternately from the server and added to the document via $("section:last").after(data);

But there was a problem: there is an anchor on each landing section and a menu item is tied to this anchor.

Question: How to implement navigation, if in fact none (at start) or several (when viewed) sections are not available for viewing, and the user already clicks on their anchors?

  • The easiest option: create a function that will start scrolling on a click on the anchor. This function is called in document.ready, and then every time after ajax-loading - DaemonHK

1 answer 1

css + jquery to help you, do not be nonsense ... Why request files if you can hide and show them in any order and when you want ... Especially this code will hurt the CEO, since the robot will see only a piece of incomprehensible code ...

  • the customer demanded "as VC", well, I did not refuse him =) Thanks for the instruction on the right path. Both problems were solved in literally 10 lines of code! - griff92