javascript - Pause section and scroll inside a div -


i'm working on client site , i'm having issue firguring out how make work. goal pause @ section , continue scroll inside iphone continue scroll once iphone has finished scrolling. have attempted use position fixed on section body continues scroll i'm not sure if right solution. wondering if skrollr assist well. have ideas?

i've added fiddle of layout: https://jsfiddle.net/9lm6he4j/1/

psuedo html:

<section>     <div class="iphone_wrap">         <div class="iphone_inner">             <!--message content-->         </div>     </div> </section> 

css:

section {    position:relative;    min-height:500px;    width:100%; }  .iphone_wrap {     width:400px;     height:650px;     position:absolute;     left:20%;     top:-200px;     background:url('iphone.jpg'); }  .iphone_inner {     position:relative;     margin:0 auto;     overflow:scroll; } 

example

one way can

  • use javascript/jquery , set position fixed of "blue color section" , "iphone wrapper"

    content run inside phone implement part of underlying body of page

    so blue section + iphone wrapper work overlay while content of iphone scroll below section

    and using js/jquery can reset position fixed relative after end of content.


Comments

Popular posts from this blog

powershell Start-Process exit code -1073741502 when used with Credential from a windows service environment -

twig - Using Twigbridge in a Laravel 5.1 Package -

c# - LINQ join Entities from HashSet's, Join vs Dictionary vs HashSet performance -