javascript - HTML and style sheet not linking -


ok no matter style sheet not link html document, both in same directory on computer , no matter do, no style applied <p> tag. have stripped document bare bones , cannot find error is. i'm sure @ point extremely simple , complete idiot missing it. please help.

index.html

<!doctype html> <html> <link rel=sylesheet type=text/css href=style.css> <head> </head> <body> <p> hello, world! </p> </body> </html> 

style.css

p {     color: red; } 

your format in html not correct. should be:

<!doctype html> <html>  <head>   <link rel="stylesheet" type="text/css" href="style.css">   </head>  <body>  </body> </html> 

your <link rel="stylesheet" type="text/css" href="style.css"> should inside of <head></head> tag


Comments

Popular posts from this blog

java - Run spring boot application error: Cannot instantiate interface org.springframework.context.ApplicationListener -

reactjs - React router and this.props.children - how to pass state to this.props.children -

Excel VBA "Microsoft Windows Common Controls 6.0 (SP6)" Location Changes -