954,598 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

table help

hello, i am making a website and i need some help. I am writing a table, here is the code:

<table style='float: left;'>
  <tr><td style='width: 200px; height: 500px; background-color: red; valign: top; align: top;'><a class='mainlink' href='about.html'>About Me (under construction)</a>
  </td></tr>
  </table>

now, i want the link to align to the top of the the table. here is the css for the link

<style type='text/css'>
 body{
 background-color: black;
 color: white;
 }
 .marquee{
 font-size: 20px;
 font-weight: bold;
 }
 .mainlink{
 color: black;
 text-decoration: none;
 vertical-align: top;
 }
 .mainlink:hover{
 color: white;
 text-decoration: underline;
 }
 </style>


if someone could help asap, i would be greatful

tcollins412
Junior Poster
139 posts since Dec 2010
Reputation Points: 10
Solved Threads: 3
 

Well, i checked out your coding on Dreamweaver CS5, and your link is at the top of the table. it look like the way you want it. Can you elaborate on your issue a little more?

untitledking
Light Poster
36 posts since Mar 2010
Reputation Points: 8
Solved Threads: 2
 

on my computer, the link isnt at the top

tcollins412
Junior Poster
139 posts since Dec 2010
Reputation Points: 10
Solved Threads: 3
 

alright, i just previewed it on the browser. I see what you're talking about now, the link goes to the middle of the page, let me see what I can do. :)

untitledking
Light Poster
36 posts since Mar 2010
Reputation Points: 8
Solved Threads: 2
 

thanks

tcollins412
Junior Poster
139 posts since Dec 2010
Reputation Points: 10
Solved Threads: 3
 

here, i was able to make the words stay at the top of the page. But you will need to add more coding to suit you. Hope this helps :)

About Me (under construction)

untitledking
Light Poster
36 posts since Mar 2010
Reputation Points: 8
Solved Threads: 2
 
<table style='float: left;'>
      <tr><td style='width: 200px; height: 10px; background-color: red; valign: top; align: top;'><a class='mainlink' href='about.html'>About Me (under construction)</a>
      </td></tr>
      </table>


srry about that, forgot to add the code, lol

untitledking
Light Poster
36 posts since Mar 2010
Reputation Points: 8
Solved Threads: 2
 

I hope that untitledking's response helped, but for future reference, 'valign: top' only works on a , not on anything else...

shaya4207
Junior Poster
147 posts since Apr 2010
Reputation Points: 18
Solved Threads: 25
 

lol, I hope so too :D

It was working on my computer though.

untitledking
Light Poster
36 posts since Mar 2010
Reputation Points: 8
Solved Threads: 2
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You
View similar articles that have also been tagged: