Take the 2-minute tour ×

I've been using this sample to create a "zoomable" content: http://code.msdn.microsoft.com/windowsapps/Scrolling-panning-and-47d70d4c


<div id="zoomElement" class="zoomElement ManipulationContainer">
    <img id="zoomContent" class="zoomContent" alt="" src="sample.jpg" />


.zoomElement {
    overflow: auto;
    -ms-content-zooming: zoom;
    -ms-scroll-rails: none;
    -ms-content-zoom-limit-min: 20%;
    -ms-content-zoom-limit-max: 500%;

Now, no matter what, I've been unable to center the img in its container when it's unzoomed.

share|improve this question
Can you give more details on what you tried? –  Tarek Ayna Jan 29 '13 at 2:31
I think the issue is not about div positioning, but about -ms-content-zoom-limit-min: 20%;. When it is below 100%, the 'unzoomed' content will always be at top left of its ManipulationContainer. –  Cœur Jan 29 '13 at 10:35
add comment

Your Answer



Browse other questions tagged or ask your own question.