Live Demo


head :
<!-- Use Jquery version 1.8.x + --> <script src="js/jquery-1.8.3.min.js"></script> <!-- Call nicoNoZoom plugin file --> <script src="js/nicoNoZoom.js"></script>
HTML :
<img src="img/01.jpg" class="zoom" />
Javascript :
<script type="text/javascript">
$(window).load(function(){
$(".zoom").nicoNoZoom();
});
</script>
// Which is equivalent to :
<script type="text/javascript">
$(window).on('load', function(){
$('.zoom').nicoNoZoom({
loopSize:200,
zoomLevel:2,
cursor:'crosshair',
radius:true,
});
});
</script>
Option name | Type | Default | Exemple | Description |
---|---|---|---|---|
loopSize | int (pixels) | 200 | 400 | Size (in pixel) of the zoom window |
zoomLevel | int | 2 | 4 | Set the value of the zoom (2 = image size * 2) |
cursor | string | 'crosshair' | 'move', 'none' | CSS cursor property value |
radius | bool | true | false | Display zoom window as a circle or no |