jquery - Open Toggle container on scroll -
i'm creating website university , toggle container open when scroll part. until can find solutions toggle container open on page load.
this code
<div class="toggle-wrap"> <span id="eindhoven" class="toggle-title"><a href="#">eindhoven</a></span> <div class="toggle_container">lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.</div> <script> $(document).ready(function(){ $(".toggle_container").toggle(); }); </script>
<div class="toggle-wrap"> <span id="eindhoven" class="toggle-title"><a href="#">eindhoven</a></span> <div class="toggle_container">lorem ipsum dolor sit amet, consectetuer adipiscing elit, ed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat.</div> <script> $(document).ready(function(){ $(window).scroll(function(){ $(".toggle_container").toggle(); }) }); </script>
you can set scroll div.
Comments
Post a Comment