Images not align center in safari

hi there im stuck in this alignment issue in safari i have made a website and images or text are aligned center and it works great in CHROME,MOZ AND IE but it wont in safari i dont know how to do it im using css for aligning it on center pls help

#image
{
	max-width:100%;
	height:auto;
	display:block;
   margin-left: auto;
   margin-right: auto;
}

works in chrome,moz,IE but not in safari

Can we see the html also to put this in context?
Though I don’t have Safari to test with.
Maybe try combining the left and right margins into one rule. margin: 0 auto

1 Like

As Sam says we really need to see the HTML. However, the way to centre an inline element such as an image is with text-align rather than setting the left and right margins to auto.

That code works fine in Safari (mac) so it must be something else in your code that is causing this.

Just to avoid the obvious thing here; if this is Windows Safari, please uninstall it and forget you ever had this issue :slight_smile: .

2 Likes

Odd thing is, if you Search there are sites offering downloads of the latest Safari for Windows.

Yet if you go to the official site, there are no downloads for Windows.

What the other sites fail to mention is that Safari for Windows is not supported and using Safari in Windows will result in unexpected browser behavior.

1 Like

which was released on 20th July 2011

2 Likes

You know that, and I know that. But how many don’t if they go to a site like techspot and see

Safari Browser 5.1.7 for Windows
Developer:Apple
Last updated:May 3, 2016
License:Freeware
OS support:Windows XP/Vista/7
File size:36.7 MB
Downloads:794,899

or safari.soft32

Safari 5.1.7
Last update 30 Jul. 2014	| old versions 
Licence Free 
OS Support Windows XP, Windows Vista, Windows 7, Windows 7 x64, Windows Vista x64, Windows XP x64 
DownloadsTotal: 2,314,062 | Last week: 58
2 Likes

heres the html code

<?php
session_start();
?>
<!DOCTYPE HTML>

<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta charset="utf-8"/>
     <link href="images/mob.png" rel="icon" type="image/x-icon"/>
	<link href='https://fonts.googleapis.com/css?family=Comfortaa' rel='stylesheet' type='text/css'>
	<link rel="stylesheet" href="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/css/bootstrap.min.css">
  <script src="https://ajax.googleapis.com/ajax/libs/jquery/1.12.0/jquery.min.js"></script>
  <script src="http://maxcdn.bootstrapcdn.com/bootstrap/3.3.6/js/bootstrap.min.js"></script>
   <script src="https://ajax.googleapis.com/ajax/libs/jquery/2.2.0/jquery.min.js"></script>
   <link rel="stylesheet" type="text/css" href="css/mystyle.css">
<title>SYSP</title>
</head>
<body>
 <div class="row">
<div class="container">
<div class="row">

 <div class="col-md-6 col-lg-12 col-sm-12 col-xs-12">
 <div class="navbar navbar-custom navbar-fixed-top" id="social">
 <a href=""><img src="images/Maill.png" class="img-responsive" id="social" alt="mail"></img></a>
<a href=""><img src="images/twitter.png" class="img-responsive" id="social" alt="Twitter"></img></a>
<a href=""><img src="images/facebook.png" class="img-responsive"  id="social"alt="Facebook"></img></a>

  </div>
  </div>
  </div><br><br><br>
<div class= " col-md-6 col-lg-12 col-sm-12">
<a href="index.php"><img src="images/logo.png" id="ii" class="ii"class="img-responsive"></img></a>
<marquee><p style="color:orange;"> Site best viewed in chrome,Internet Explorer and Firefox</p></marquee>

<form action="knowmore.php" method="post">
   
	  </div>
	  <div class="col-md-6 col-lg-12 col-sm-12">
<nav class="navbar navbar-default">
  <div class="container-fluid">
    <div class="navbar-header">
      <button type="button" class="navbar-toggle" data-toggle="collapse" data-target="#myNavbar">
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span> 
      </button>
    </div>
    <div class="collapse navbar-collapse" id="myNavbar">
      <ul class="nav navbar-nav">
	  <ul>
	<?php if(empty($_SESSION)):?>
<li><a href="index.php">HOME</a></li>
<?php endif;  ?>

<?php if(!empty($_SESSION)):?>

<?php if($_SESSION['type']=="ngo"):?>
<li><a href="profile2.php" >PROFILE</a></li>
<?php else:?>
<li><a href="profile.php" >PROFILE</a></li>
<?php endif;  ?>

<?php endif;  ?>

<li><a href="contact.php">CONTACT US </a></li>
<li><a href="#" >BLOG/UPDATES</a></li>

<?php if(empty($_SESSION)):?>
<li><a href="login.php" >LOGIN</a></li>
<?php else:?>
<li><a href="logout.php" >LOGOUT</a></li>
<?php endif;  ?>
<?php if(empty($_SESSION)):?>
<li><a href="register.php">REGISTER</a></li>
<?php endif;?>


  </ul>
</ul>
    </div>
  </div>
</nav>
</div>
	    
  </div>
  </div>

<div class="row">
<div class=" col-md-6 col-lg-12 col-sm-12 col-xs-12">
<img src="images/Land.jpg" id="land" class="img-responsive"></img>  
<br><br>
</div><br>
</div>
</div>
<div class="row">
<div class="col-md-6 col-lg-12">
<button type="submit" class="btn btn-default" id="reg">Click To Know More</button>
</div>
</div><br><br>
 <footer id="mainfoot">
<p id="foot"> &copy Rann Neeti Strategic Consultants Pvt. Ltd. || 2016</p>
</footer>
  </form>
</body>
</html>

We asked which version of Safari you are using. Please tell us which version of Safari you are using and on which platform.

i dont have mac i tested on my friends laptop and in i pad and 9.1 the latest browser i tested it out

You told us what you do not have, but you did not specify what type of laptop your friend has. Does your friend have a laptop Mac?

If yes, then please capture a full rez screenshot on your friends Mac showing how the images and text do not align properly and post that screenshot in your next message. Do not crop the screenshot smaller than it should be.

Thank you

if you have any of apple product check it out

In post #4, @PaulOB stated that he checked it out on a Mac and your code looked good.

did he checked it out in ipad?

Make up your mind. You did not specify that your testing environment was an ipad.

Is there an on-line testing service that you can use to render your code in your choice of Mac products?

i guess i missed that part well i wanted to test in i pad i tried testing online but no use :frowning:

Do you have a problem with your text and images aligning correctly in Safari on some device or do you not? Are you just seeking testing services from us to prove that your code works?.. because Paul did not see a problem.

see i tested in chrome moz and IE also on safari but not on ipad safari thers issue on i pad safari and text images are fine except in i pad i dont know why is this happening

I seriously doubt that the HTML with PHP in post #9 will help us diagnose a problem. We need to see a real working page that demonstrates the problem. We will probably need a link to your web site.

You will have to wait until someone with an iPad joins this conversation.

In the meanwhile, perhaps you will have better luck getting a screenshot from a service like

or

They both claim to offer free trials.