HTML Introduction to HTML and CSS Adding a New Web Page Write the CSS

jake bemar
jake bemar
671 Points

unable to link html to css

read the answers and tried them all but still unable to connect. not sure on how to send a snapshot of my code. please help. thank you.

jake bemar
jake bemar
671 Points

thanks steven that helped.

Steven Parker
Steven Parker
201,355 Points

Did you want to share a link to illustrate your issue?

jake bemar
jake bemar
671 Points

i managed to figure out what the problem was but thank you i appreciate your help.

1 Answer

Sam Natale
Sam Natale
1,500 Points

Example

If your file directory looks like this:

folder
    index.html
    styles.css

Then to link the style css you will need to type the following code in your html:

<link rel="stylesheet" href="styles.css">

However if your file directory looks like this for example:

folder
    index.html
    folder2
        styles.css

Then to link the style css you will need to type the following code in your html:

<link rel="stylesheet" href="folder2/styles.css">

Hope this helps, if not please reference your code so we can help you out.

jake bemar
jake bemar
671 Points

thanks for your help. i appreciate it.