R
R
Roman2015-05-28 11:05:23
css
Roman, 2015-05-28 11:05:23

How to size SVG logo in Safari?

Safari 5.1.7 distorts logo dimensions:
f9d72a76fabb4f9e8693affcf75344bb.PNG
HTML:

<div id=logo">
<a href="/" alt="">
<img src="logo.svg" alt="logo" itemprop="contentUrl">
</a>
</div>

CSS:
#logo img {
  display: block;
  max-width: 100%;
  width: 140px;
  height: 100px;
  margin: 0;
}

How to fix?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
R
Roman, 2015-06-24
@llgruff

Duplication for div helped:

#logo {
width: 140px;
height: 100px;
}

and adding for img:
#logo img {
border:none;
}

A good example of a svg logo without bugs and cross-browser is here .

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question