Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Internet Explorer - <img> width not taking effect?

I have an issue in IE9 with IMG width, it can be seen here, http://ncms.us/ncms/admin/login the only issue I see is that I'm using ' instead of " for my tags because its within a PHP echo. The main picture up at the header is huge on IE (IE9+IE10 tested.) looks fine in everything but IE. Here is the code that is throwing IE off. I can see why, its very complex and nothing its seen before (-_- lol)

<img style='margin-top: -25px;' src='img/ncms_logo.png' width='300' height='250' />

Yay for IE!

like image 527
Necro. Avatar asked Jul 28 '26 05:07

Necro.


1 Answers

It looks like in your bootstrap.min.css there is a default class from img. that has the property width:auto;

If this is removed it will display properly in IE.

Additionally just adding

 width: 300px;

in your style along with the margin, will correct the issue.

like image 115
OneRealWinner Avatar answered Jul 31 '26 20:07

OneRealWinner



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!