Top Story
Tuesday, 27 June, 2017
 Register with Sunmarg News. E-paper
    Now read Sunmarg News online, exactly the way it appears in print.

    Please fill in the details below to register.
*Your Email Id 
* Password 
* Confirm Password  
* Name 
* Gender  Male Female
Phone  
*Mobile 
 * Address 
 * City 
* Country 
Clip image
First
Prev
Next
Last
//var hdsw = screen.width; var scrollHeight = 201; function loadApp() { // Create the flipbook var pageheight=document.getElementById('pageheight').value; hdswidth=768; hdsheight=pageheight; var oTurn = $('.flipbook').turn({ // Width width:hdswidth, // Height height:hdsheight, // Elevation elevation: 50, // Enable gradients gradients: true, // Auto center this flipbook autoCenter: true, }); $("#prev").click(function(e){ if(document.getElementById('turnpagenumber').value=="1"){ alert('you are viewing the first page.'); return false; } var preval; if(document.getElementById('turnpagenumber').value==""){ preval=2; }else{ var p=document.getElementById('turnpagenumber').value; preval=p-1; } document.getElementById('turnpagenumber').value=preval; document.getElementById('outdivd'+preval).style.display="block"; try{ for(var i=1;i<=document.getElementById('totalpages').value;i++){ if(i==preval){ document.getElementById("selectednumber"+i).style.color="red"; }else{ document.getElementById("selectednumber"+i).style.color="black"; } } for(var i=1;i<=document.getElementById('totalpages').value;i++){ if(i==preval){ var pagechangeidselected="pgmain"+i; document.getElementById(pagechangeidselected).outerHTML=document.getElementById(pagechangeidselected).outerHTML.replace('pagethumb','pagethumbselect'); document.getElementById(pagechangeidselected).outerHTML=document.getElementById(pagechangeidselected).outerHTML.replace('grthumbpgnumber','orgthumbpgnumber'); document.getElementById(pagechangeidselected).outerHTML=document.getElementById(pagechangeidselected).outerHTML.replace('thumbtitle','thumbtitleselect'); } else {var pagechangeid="pgmain"+i; document.getElementById(pagechangeid).outerHTML=document.getElementById(pagechangeid).outerHTML.replace('pagethumbselect','pagethumb'); document.getElementById(pagechangeid).outerHTML=document.getElementById(pagechangeid).outerHTML.replace('orgthumbpgnumber','grthumbpgnumber'); document.getElementById(pagechangeid).outerHTML=document.getElementById(pagechangeid).outerHTML.replace('thumbtitleselect','thumbtitle');} } } catch (err) { //alert(err); } e.preventDefault(); oTurn.turn("previous"); $('.map').maphilight({ fillColor: '008800' }); $('.borderimage').darkTooltip(); }); $("#next").click(function(e){ if(document.getElementById('totalpages').value==document.getElementById('turnpagenumber').value){ alert('you are viewing the last page.'); return false; } var nextval; if(document.getElementById('turnpagenumber').value==""){ nextval=2; }else{ nextval=parseInt(document.getElementById('turnpagenumber').value)+parseInt(1); } document.getElementById('turnpagenumber').value=nextval; document.getElementById('outdivd'+nextval).style.display="block"; try{ for(var i=1;i<=document.getElementById('totalpages').value;i++){ if(i==nextval){ document.getElementById("selectednumber"+i).style.color="red"; }else{ document.getElementById("selectednumber"+i).style.color="black"; } } for(var i=1;i<=document.getElementById('totalpages').value;i++){ if(i==nextval){ var pagechangeidselected="pgmain"+i; document.getElementById(pagechangeidselected).outerHTML=document.getElementById(pagechangeidselected).outerHTML.replace('pagethumb','pagethumbselect'); document.getElementById(pagechangeidselected).outerHTML=document.getElementById(pagechangeidselected).outerHTML.replace('grthumbpgnumber','orgthumbpgnumber'); document.getElementById(pagechangeidselected).outerHTML=document.getElementById(pagechangeidselected).outerHTML.replace('thumbtitle','thumbtitleselect'); } else {var pagechangeid="pgmain"+i; document.getElementById(pagechangeid).outerHTML=document.getElementById(pagechangeid).outerHTML.replace('pagethumbselect','pagethumb'); document.getElementById(pagechangeid).outerHTML=document.getElementById(pagechangeid).outerHTML.replace('orgthumbpgnumber','grthumbpgnumber'); document.getElementById(pagechangeid).outerHTML=document.getElementById(pagechangeid).outerHTML.replace('thumbtitleselect','thumbtitle');} } } catch (err) { //alert(err); } e.preventDefault(); oTurn.turn("next"); $('.map').maphilight({ fillColor: '008800' }); $('.borderimage').darkTooltip(); //setTimeout('setdivpos()',1000); pagechange(document.getElementById('turnpagenumber').value); }); $("#zoom-viewport").bind("zoom.swipeLeft", function(event) { //$("#bookfliphds").turn("next"); alert('next'); }); $("#zoom-viewport").bind("zoom.swipeRight", function(event) { //$("#bookfliphds").turn("previous"); alert('previous'); }); } // Load the HTML4 version if there's not CSS transform yepnope({ test : Modernizr.csstransforms, yep: ['lib/turnsingle.js'], nope: ['lib/turn.html4.min.js'], both: ['css/basic.css'], complete: loadApp });
 
  • Full Page
    Custom Area
    • Follow us :  

    Copyright @ 2016 eZineMart. All Rights Reserved.