編集:私がしたことは、私が以下に書いたこととは異なりますが、現在は機能しています。理由がわからない:-/助けてくれてありがとう:)
ドキュメントを css ファイルにリンクしようとしています。問題はそれです。
これは機能します:
<link rel="stylesheet" type="text/css" href="style.css">
この用量:
<link rel="stylesheet" type="text/css" href="css/style.css">
もちろん、ファイルにリンクしようとすると、サブフォルダーにファイルが存在します。
:)
編集:
HTMLファイル
<link rel="stylesheet" type="text/css" href="/css/style.css">
</head>
<body>
<table id="menu">
<tr>
<td><a id="button">Home</a></td>
<td><a id="button">Education</a></td>
<td><a id="button">Experience</a></td>
<td><a id="button">Gallery</a></td>
<td><a id="button">Cantact Me</a></td></tr>
</table>
私のhtmlエディター(Expression Web)でのみ機能したようですが、ブラウザー(chrome/firefox/ie)で開くと機能しません。
スタイル ファイル:
body{ background-color: white;}
#menu { width:100%; background-image:url('BarBG.png'); border:0px; }
#button
{
color:white;
font-size:large;
line-height:45px;
vertical-align:middle;
text-align:center;
display: block;
width: 100px;
height: 45px;
margin-right:auto;
margin-left:auto;
}
#button:hover{
color:black;
font-size:large;
line-height:45px;
vertical-align:middle;
text-align:center;
display: block;
width: 100px;
height: 45px;
margin-right:auto;
margin-left:auto;
background-image:url('BarBGHover2.png');
cursor:pointer;
}