JQuery Mobile has a series of effects on how to transition from one page to the next page. The premise is that the browser must support CSS3 3D conversions:
Browser support
- Internet Explorer 10 supports 3D conversions (earlier versions are not supported)
- Opera still does not support 3D conversion
Transition effects can be applied to any link or form submission by using the Data-transition property:
The following table shows the available transitions that can be used with the Data-transition property:
All of the above effects support reverse motion at the same time, for example, if you want the page to swipe from left to right, rather than to the left, use the Data-direction property with the value "reverse". On the Back button is the default.
<!DOCTYPE HTML><HTML><Head><Metahttp-equiv= "Content-type"content= "text/html; charset=utf-8" /><title></title></Head><Linkrel= "stylesheet"href= "Http://code.jquery.com/mobile/1.3.2/jquery.mobile-1.3.2.min.css"><Scriptsrc= "Http://code.jquery.com/jquery-1.8.3.min.js"></Script><Scriptsrc= "Http://code.jquery.com/mobile/1.3.2/jquery.mobile-1.3.2.min.js"></Script></Head><Body> <DivData-role= "page"ID= "Pageone"> <DivData-role= "header"> <H1>HEADER</H1> </Div> <DivData-role= "Content"> <P>Click the link to see the slide effect</P> <ahref= "#pagetwo"data-transition= "Slide">Swipe to page two</a> </Div> <DivData-role= "Footer"> <H1>FOOTER</H1> </Div> </Div> <DivData-role= "page"ID= "Pagetwo"> <DivData-role= "header"> <H1>I am a dialog box!</H1> </Div> <DivData-role= "Content"> <P>Click the link to see the slide effect</P> <ahref= "#pageone"data-transition= "Slide">Swipe to page One</a><!--Add this property data-direction= "reverse" to enable reverse sliding - </Div> <DivData-role= "Footer"> <H1>Footer text</H1> </Div></Div> </Body></HTML>