Jump to content

Font Issue in w3.css - not displaying font correctly


psycoperl_nyc

Recommended Posts

I downloaded the latest w3.css framework and updated the css for html, body to use a different font-family.

html,body{font-family:'Lato','Open Sans',font-weight:300;sans-serif;font-size:15px;line-height:1.5}html{overflow-x:hidden}

However when I did that the font that is now displayed when I use the following code displays an incorrect (and serif) font. 

<div class="w3-container w3-panel w3-card-2 w3-blue"> <b>System Alert:</b> <br /> System currently in <em>Development Mode</em> </div> 

 

What gives? How can I get this to resolve. 

Link to comment
Share on other sites

I imagine that you have a <body> and <html> tags elsewhere.

Have you tried using the browser dev tools, if you select that div you can see what stylings are being applied to it.

Your CSS is a little interesting, your sans-serif font declaration seems to be after your font-weight? with no semi-colon in between it may be erroring out.

 

  • Thanks 1
Link to comment
Share on other sites

You haven't specified a generic fallback font (usually serif or sans-serif) and you forgot a semi-colon after the font-family rule.

  • Thanks 1
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...