I have this:
<p>
<img src="media/icons/info_ticket.png"></img>
<h3>Ticket #TKMA<span><?php echo $_GET['CRy3sjzZOJyXE']; ?></span></h3>
</p>
And when I apply CSS to change the style of the img
it doesn't work! So, I inspected the element and I found this:
<p>
<img src="media/icons/info_ticket.png">
</p>
<h3>Ticket #TKMA<span>17</span></h3>
<p></p>
I don't understand why this happens.
Because your HTML is invalid. <p>
elements can only contain phrasing content.
See List of HTML5 elements that can be nested inside P element?
The reason is because, an H
element inside a <p>
element isn't valid so the browser corrects it by pulling it out.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With