htmlcsswordpressxhtml

Image height and width not working?


On this post I have set the image height and width and it's clearly seen in the HTML..

[url removed]

But the browser or Wordpress is causing the image to stay same size.

I want it to be smaller?


Solution

  • You must write

    <img src="theSource" style="width:30px;height:auto;" />
    

    Inline styling will always take precedence over CSS styling. The width and height attributes are being overridden by your stylesheet, so you need to switch to this format.