wbmkk
New Member
Hello
I've be doing a bit of CSS practice and found that I can not align vertically my navigation links, so the wording sits nicely inside the imaginary button.
Can anybody assist please.
See attached code & CSS below
<html>
<head>
<style type="text/css">
a {
display: block;
border: 2px solid;
border-color: white black black white;
height:3em;
width: 8em;
display:table-cell;
vertical-align:middle;
text-align:center;
background: #CC9933;
margin-bottom:1em;
}
a:hover
{
position: relative;
top: 1px;
left: 1px;
border-color: black white white black;
}
</style>
</head>
<body>
<a href="http://www.yahoo.co.uk">Yahoo</a><br />
<a href="http://www.Google.com">Google</a><br />
<a href="http://www.yahoo.co.uk">Yahoo is here</a><br />
<a href="http://www.yahoo.co.uk">Yahoo</a><br />
</body>
</html>
Many thanks in advance
I've be doing a bit of CSS practice and found that I can not align vertically my navigation links, so the wording sits nicely inside the imaginary button.
Can anybody assist please.
See attached code & CSS below
<html>
<head>
<style type="text/css">
a {
display: block;
border: 2px solid;
border-color: white black black white;
height:3em;
width: 8em;
display:table-cell;
vertical-align:middle;
text-align:center;
background: #CC9933;
margin-bottom:1em;
}
a:hover
{
position: relative;
top: 1px;
left: 1px;
border-color: black white white black;
}
</style>
</head>
<body>
<a href="http://www.yahoo.co.uk">Yahoo</a><br />
<a href="http://www.Google.com">Google</a><br />
<a href="http://www.yahoo.co.uk">Yahoo is here</a><br />
<a href="http://www.yahoo.co.uk">Yahoo</a><br />
</body>
</html>
Many thanks in advance