Solved

how to get a table to align to top of a cell

Posted on 2003-11-17
6
222 Views
Last Modified: 2010-04-06
Hi,
I have a cell that contains a table and I would like to get the table to sit at the top of that cell rather than hover in the middle.  Is there any way I can do this?

Many thanks,
James
0
Comment
Question by:altnoise
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
6 Comments
 
LVL 17

Accepted Solution

by:
dorward earned 50 total points
ID: 9762817
Nested tables? Oh dear: http://dorward.me.uk/www/nested/

The solution (if you want to continue with the nasty hack is):

Modern (although an external style sheet is preferred):
<td style="vertical-align: top;">   <table> </table>  </td>

1996:
<td valign="top">  <table> </table>  </td>

0
 

Expert Comment

by:icepricessa
ID: 9785455
i agree with dorward...

you should do this <td valign="top">  <table> </table>  </td>

hope it works :)
0
 
LVL 17

Expert Comment

by:dorward
ID: 9785786
icepricessa: I wasn't suggesting that people _should_ use the obsolete 1996 technique.
0
Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 
LVL 11

Expert Comment

by:Zontar
ID: 9790183
Um, technically, valign isn't "obsolete" -- it's not deprecated in the HTML 4 spec (for TD or TH at least).

Not that I don't agree that CSS is better -- or that not using nested tables in the first place is even better yet! -- just nitpicking. ;^)
0
 
LVL 17

Expert Comment

by:dorward
ID: 9791111
"Deprecated" and "obsolete", while applying to a lot of the same parts of HTML, are not synonyms
0
 

Author Comment

by:altnoise
ID: 9809535
Thanks for your help!  I agree though nested tables are a little bit of a quick fix.  I'll try and improve my design practices.
Thanks,
James
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Article by: Matthew
I am a very big proponent of technology compliance standards and strive to meet such criteria in all of my work. That includes my site, which is 100% XHTML 1.0 compliant as determined by the World Wide Web Consortium. https://www.matthewstevenkel…
Have you tried to learn about Unicode, UTF-8, and multibyte text encoding and all the articles are just too "academic" or too technical? This article aims to make the whole topic easy for just about anyone to understand.
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:
This tutorial will teach you the core code needed to finalize the addition of a watermark to your image. The viewer will use a small PHP class to learn and create a watermark.

751 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question