jimmythearchitect Posted May 31, 2015 Share Posted May 31, 2015 I am building my first web site using HTML, CSS, and Bootstrap. After extensive searching, I can’t get my HTML file to link with my CSS file. The HTML document and CSS document are in the same domain so there shouldn’t be any reason to mention a file in the code, but my CSS isn’t affecting the HTML when I load it in Chrome. Any help would be greatly appreciated. I have enjoyed learning how to make a website, but this is hampering my progress/enjoyment. Below is some of the code (most comes from the Bootstrap site with minor customization). <head><meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width, initial-scale=1"><!--[if lt IE 9]><script src="https://oss.maxcdn.com/html5shiv/3.7.2/html5shiv.min.js"></script><script src="https://oss.maxcdn.com/respond/1.4.2/respond.min.js"></script><![endif]--> <title>TruNord</title><link href=“GOOGLE FONT PAGE” rel=“stylesheet” /><link href=“css/bootstrap.min.css” rel=“stylesheet” /><link href=“main.css” type=“text/css” rel=“stylesheet” /></head> Link to comment Share on other sites More sharing options...
Ingolme Posted May 31, 2015 Share Posted May 31, 2015 It looks like you're not using a proper code editor to write your code. Your code has curly quotes “”, while the code is meant to have ordinary quotes " " 1 Link to comment Share on other sites More sharing options...
jimmythearchitect Posted June 2, 2015 Author Share Posted June 2, 2015 Hmmm, thanks I'll try that out. I'm using Text Editor on Mac. I made sure my settings were done in such a way that it would be plain text and not rich text, but maybe there is still something wrong there. I will check. Thank you. Link to comment Share on other sites More sharing options...
Alatoru Posted June 10, 2015 Share Posted June 10, 2015 CSS files are linked to the html like this: <link rel="stylesheet" type="text/css" href="URL where is CSS file" /> rel means relationship and tells to browser what is relation between html file and css. href is HypertextReferance, which tells where to look for something. 1 Link to comment Share on other sites More sharing options...
shaili_shah Posted May 23, 2019 Share Posted May 23, 2019 link your css file using below: <link rel="stylesheet" href="yourCssFile.css"> Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now