Question

While browsing the mobile site, we can't pinch zoom the window size because the pinch zoom function is disabled.

But I want enable the pinch zoom function on a popup window when user click the small image on the site, so that they can pinch zoom that image on the popup window.

Is jQuery or JavaScript can achieve this function?

Thanks

Was it helpful?

Solution 2

Just find a jQuery plugin to achieve this action, https://github.com/eightmedia/hammer.js

OTHER TIPS

Yes, it can be achieved with JavaScript. I have recently done the same thing.

You need to bind to touchstart, touchmove and touchend events and use event.scale with transform: scale() to do it.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top