Reputation: 447
I have a html code:
<div style="width:100%;word-wrap:break-word;;" align="justify">
<p style="text-align: justify;" align="justify">
<img class="news-image" alt=" Thời trang"
src="http://img-hcm.24hstatic.com/upload/3-2012/images/2012-09-13/1347508625-lan-khue1.jpg"
style="font-size: medium; font-family: "Times New Roman";max-width:95%;">
</p>
</div>
I don't know why max-width
of img
dosen't work. If I remove p
tag, it works.
Is there anyway to use max_width
inside p
tag.
Upvotes: 1
Views: 894
Reputation: 10490
You can't use double "
quotation mark around your font it breaks the html use singular '
instead
change:
<img class="news-image" alt=" Thời trang"
src="http://img-hcm.24hstatic.com/upload/3-2012/images/2012-09-13/1347508625-lan-khue1.jpg"
style="font-size: medium; font-family: "Times New Roman";max-width:95%;">
TO:
<img class="news-image" alt=" Thời trang"
src="http://img-hcm.24hstatic.com/upload/3-2012/images/2012-09-13/1347508625-lan-khue1.jpg"
style="font-size: medium; font-family: 'Times New Roman';max-width:95%;">
Upvotes: 2