HTML/CSS/CSS Controls/CSS Button

Материал из Web эксперт
Перейти к: навигация, поиск

CSS Button with anchor

 
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>CSS Button</title>
<style type="text/css">
body {
  font: 140%/1.6 "Gill Sans", Futura, "Lucida Grande", Geneva, sans-serif;
  color: #666;
  background: #fff;
}
a:link, a:visited {
  display: block;
  width: 6em;  
  padding: 0.2em;
  line-height: 1.4;
  background-color: #94B8E9;
  border: 1px solid black;
  color: #000;
  text-decoration: none;
  text-align: center;
}
a:hover {
 background-color: #369;
 color: #fff;
}
</style>
</head>
<body>
<p><a href="#">Button</a></p>
</body>
</html>