html - Why is my CSS style not being applied? -


i've got html:

<p>     <span class="fancify">parting such sweet sorrow!</span><span> - bill rattleandrollspeer</span> </p> 

...and css (added bottom of site.css):

.fancify {     font-size: 1.5em;     font-weight: 800;     font-family: consolas, "segoe ui", calibri, sans-serif;     font-style: italic; } 

so, expect quote ("parting such sweet sorrow!") italicized, , of different font name of quotee (bill rattleandrollspeer), since span tag has class "fancify" attached it. class should seen, file in appears references layout file uses site.css file.

what rookie mistake making now?

update

i thought maybe problem had added new class in site.css following section in file:

/******************** *   mobile styles   * ********************/ @media screen , (max-width: 850px) { 

...but moved above there, , still not working, , not seen via f12 | inspect element label in question.

i moved reference site.css below bootstrap.css file, indeed change appearance of text, still not italicized, , still not seen in element inspector...

update 2

here's how html coming down:

<p>     <span>         <label class="fancify">parting such sweet sorrow!</label> 

...and here's css rule in site.css:

p span label .fancify {         font-size: 1.5em;         font-weight: 800;         font-family: consolas, "segoe ui", calibri, sans-serif;         font-style: italic;         display: inline;     } 

...but it's not being recognized. consider breech of css/html protocol, , should adjudicated world body. again, making silly mistake somewhere.

have tried forcing selectors in front of class ?

p span label.fancify {      font-size: 1.5em;     font-weight: 800;     font-family: consolas, "segoe ui", calibri, sans-serif;     font-style: italic; } 

usually add more weight css declaration. mistake ... should no space between selector , class same goes id. if have example.

<div id="first">     <p id="myparagraph">hello <span class="bolder">world</span></p> </div> 

you style

div#first p#myparagraph {      color : #ff0000; } 

just make complete example using class ...

div#first p#myparagraph span.bolder{     font-weight:900; } 

you have pseudo-selector , child selectors looks reference here : http://www.w3.org/tr/css2/selector.html

css whole science :) , beware, browser show incompatibilities , not show proper results.

another site : http://www.caniuse.com/

hope makes sense.


Comments

Popular posts from this blog

c# - DetailsView in ASP.Net - How to add another column on the side/add a control in each row? -

javascript - firefox memory leak -

Trying to import CSV file to a SQL Server database using asp.net and c# - can't find what I'm missing -