Can anyone explain why the CSS is not implemented when using a span class for marking up a letter, but it works fine with a div class? I thought both should work, considering one is a block-level element and the other is inline. Here's the line that was changed:
<div class="receiver-column"> 20 January 2016 </div>
changed to
<span class="receiver-column">20 January 2016 </span>
This is the HTML code snippet provided:
body {
max-width: 800px;
margin: 0 auto;
}
.receiver-column {
text-align: right;
}
h1 {
font-size: 1.5em;
}
h2 {
font-size: 1.3em;
}
p,
ul,
ol,
dl,
address {
font-size: 1.1em;
}
p,
li,
dd,
dt,
address {
line-height: 1.5;
}
<p class="receiver-column"><strong>Dr. Eleanor Gaye </strong> Awesome Science faculty <br> University of Awesome <br> Bobtown, CA 99999, <br> USA <br>
<strong>Tel</strong>: 123-456-7890 <br>
<strong>Email</strong>: <a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="e48a8bbb968194889da4819c8589948881ca873feb">[email protected]</a> </p>
<div class="receiver-column"> 20 January 2016 </div>