Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > HTML > tables

Reply
Thread Tools

tables

 
 
KED
Guest
Posts: n/a
 
      09-07-2006
i was wondering how to align a table exactly where you want it on a
page.

by that i mean if i want the table in the center, or the left.
Basically how do i get the table exactly where i want it on the page.

 
Reply With Quote
 
 
 
 
David Dorward
Guest
Posts: n/a
 
      09-07-2006
KED wrote:

> by that i mean if i want the table in the center, or the left.
> Basically how do i get the table exactly where i want it on the page.


Alter the left and right margins in the stylesheet, both auto to centre it,
one at 0 to align it to that side.

--
David Dorward <http://blog.dorward.me.uk/> <http://dorward.me.uk/>
Home is where the ~/.bashrc is
 
Reply With Quote
 
 
 
 
Harlan Messinger
Guest
Posts: n/a
 
      09-07-2006
KED wrote:
> i was wondering how to align a table exactly where you want it on a
> page.
>
> by that i mean if i want the table in the center, or the left.
> Basically how do i get the table exactly where i want it on the page.
>


<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
"http://www.w3.org/TR/html4/strict.dtd">
<html>

<head>
<title>Table Alignment</title>
<style type="text/css">
table { border: thin solid black; }
table.left { margin-left: 0; margin-right: auto; }
table.right { margin-left: auto; margin-right: 0; }
table.center { margin-left: auto; margin-right: auto; }
</style>
</head>

<body>
<table class="left"><tr><td>LEFT</td></tr></table>
<table class="right"><tr><td>RIGHT</td></tr></table>
<table class="center"><tr><td>CENTER</td></tr></table>
</body>

</html>
 
Reply With Quote
 
KED
Guest
Posts: n/a
 
      09-07-2006
thanks for the help. but i am an extreme newbie with this. any more
help?

David Dorward wrote:
> KED wrote:
>
> > by that i mean if i want the table in the center, or the left.
> > Basically how do i get the table exactly where i want it on the page.

>
> Alter the left and right margins in the stylesheet, both auto to centre it,
> one at 0 to align it to that side.
>
> --
> David Dorward <http://blog.dorward.me.uk/> <http://dorward.me.uk/>
> Home is where the ~/.bashrc is


 
Reply With Quote
 
Beauregard T. Shagnasty
Guest
Posts: n/a
 
      09-07-2006
KED wrote:

> thanks for the help. but i am an extreme newbie with this. any more
> help?


In that case, why not consider dropping the (learning of) old-style use
of tables for layout and move into the 21st century? Use CSS.

Lots of links to layouts here.
http://allmyfaqs.net/faq.pl?Tableless_layouts

Here's a reasonably good tutorial with CSS included:
http://htmldog.com/

--
-bts
-Motorcycles defy gravity; cars just suck.
 
Reply With Quote
 
KED
Guest
Posts: n/a
 
      09-07-2006
greatly appreciated


Beauregard T. Shagnasty wrote:
> KED wrote:
>
> > thanks for the help. but i am an extreme newbie with this. any more
> > help?

>
> In that case, why not consider dropping the (learning of) old-style use
> of tables for layout and move into the 21st century? Use CSS.
>
> Lots of links to layouts here.
> http://allmyfaqs.net/faq.pl?Tableless_layouts
>
> Here's a reasonably good tutorial with CSS included:
> http://htmldog.com/
>
> --
> -bts
> -Motorcycles defy gravity; cars just suck.


 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to get database metadata information (i.e. existing tables and columns in tables) Chris Brat Python 5 08-22-2006 05:25 PM
New AMD Turion 64 OPN & ID Tables Silverstrand Front Page News 0 09-05-2005 02:17 PM
Tables within tables Otuatail HTML 7 08-02-2004 04:42 AM
Problem printing tables hbmath Firefox 0 08-23-2003 10:35 PM
Text after 2 tables actually appears between 2 tables ! Peter Bassett HTML 3 08-15-2003 06:46 PM



Advertisments