Computer Science Canada

Html Links

Author:  uberwalla [ Thu Mar 15, 2007 7:40 pm ]
Post subject:  Html Links

Hey guys wats up i'm having a little trouble with links. i have some css code with the links so that they have a border on top and bottom and stuff. i have to links at the moment as i'm trying to figure this out.

on to explanation lol Confused

anyways the two links are right beside each other and i want them to be but they look like one word. i'm trying to find a way to separate them into two words. here is my code:

CSS:
Quote:

#Nav{
float: left;
width: 948px;
height: 18px;
border-top: 1px solid #FFA701;
border-right: 1px solid #000;
border-left: 1px solid #000;
border-bottom: 1px solid #FFA701;
}

#Nav a{
float: left;
padding: 0;
margin: 0;
height: 18px;
color: #fff;
text-transform:uppercase;
text-decoration: none;
font-weight: bold;
overflow: hidden;
}


HTML:
Quote:

<html>
<link href="code.css" type="text/css" rel="stylesheet">
<body bgcolor="#000">

<div id="Nav">
(a href="#" class="">Home</a>
(a href="#" class="">TEST</a>
</div>

</body>
</html>


ok in the html change the ( brackets to [ u changed because when i originally posted this it put it actually like a link.

thx in advance

Author:  PaulButler [ Fri Mar 16, 2007 10:52 am ]
Post subject:  Re: Html Links

Well, first of all, you should close the <a> tag like this:

HTML:

<a href="#">Home</a>
<a href="#"></a>


Since there is a linebreak between the links in the HTML code, it should translate into a space in the page. I don't see anything in the CSS that would cause this.

Author:  uberwalla [ Fri Mar 16, 2007 4:23 pm ]
Post subject:  Re: Html Links

o man i guess it cut off the closing of the links Confused i had them in the real code Smile

anyways thx for your help, but i got it fixed. i needed a horizontal list. Who knew i'd actually have to use a list in my life Razz


: