我的CSS不会链接到我的HTML文件 [英] My CSS won't link to my HTML file

查看:82
本文介绍了我的CSS不会链接到我的HTML文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我试图在Sublime Text Editor 2中建立一个简单的网站,但是我的CSS文件无法链接到我的HTML文件,因此只能打印纯文本。我的HTML代码是:

I am trying to build a simple website in Sublime Text Editor 2, however, my CSS file won't link to my HTML file and therefore printing plain text. My HTML code is:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/       xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>Christopher Olson</title>
<link href="http://fonts.googleapis.com/css?family=Open+Sans:300,600,700" rel="stylesheet" />

<link rel="stylesheet" href="css/style.css" />

据我所知,最后一行应该链接CSS文件。

As far as I know, the last line is supposed to link the CSS file.

这是我拥有的CSS的一部分:

This is part of the CSS that I have:

body, input, textarea
{
    font-family: 'Open Sans', sans-serif;
    line-height: 1.85em;
    color: #888;
    font-weight: 300;
}

有什么要解决的想法吗?请帮忙

Any ideas to fix? Please help

编辑:我有标签,我已经没空了才能张贴它

I have the tags, I just ran out of room to post it

推荐答案

肯定是您的链接的href错误。

Definitely is your link's href incorrect.

这篇关于我的CSS不会链接到我的HTML文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆