Css - margin: 0 auto



i have some html:

       <div id="logo">
          <img class="index-logo" src="img/logo.png">

if i set in css margin 0 auto for .index-logo in browser and emulator it works correct, but when i open it in mobile devices the img aligned to the left side. How to center it?

The same in ion-header-bar tag.


Have you tried using

text-align: center;

on the #logo div? I tested this code in my app on an android device and it works properly: jsfiddle