how to specify image size in pixels

前端 未结 5 1185
忘掉有多难
忘掉有多难 2020-12-19 02:20

Quick question about specifying the size of images in pixels:

\"logo\"

5条回答
  •  时光说笑
    2020-12-19 02:42

    As far as I know, you do not add the px label to width/height attribute values on the img tag itself, and I believe (though could be wrong) it's because pixels are used regardless. In CSS, however, one may use different units to specify width and height, therefore it is appropriate to add the label when using CSS.

提交回复
热议问题