Stephen Geraghty wrote:
<Clipped>

First of all, many thanks for your comprehensive replies.

I should note that I am no expert with either html coding nor css but
I am picking it up. It would obviously pay dividends for me to learn
css.

In the interim David can I clarify something giving my very basic
understanding? I have my html page created in SeaMonkey Composer - are
you saying that I just insert:
Yes. This must be on a single line without the appearance of "word wrap" as seen below
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
"http://www.w3.org/TR/html4/loose.dtd";>
as the first line....

then:

<div>
<div style="margin-left: auto; margin-right: auto;">
<TABLE....>
</TABLE>
</div>
(I want the page to center in every browser so will the above do
this?)
Yes. The reason I left out the "CSS Width: declaration is because SM Composer will automatically insert the width dimension when you create the table.

Given my lack of knowledge I see CSS and Standard HTML use as 2
seperate things..... therefore am I mixing the 2 here? In short - will
inserting your suggested code into my existing HTML documents be okay?
Yes. CSS and HTML have many of the same attributes and can be used interchangeably. Once you get a good understanding of CSS you will see the advantage of using CSS in place of HTML formatting tags. You will be able to insert all the CSS formatting tags into the <Head> section of your document to control all formatting aspects of that document.

You will also learn how to write an external CSS document and link it to all your HTML documents to control all formatting attributes for all your pages.

If you had a web site with 100 HTML documents, and all 100 pages contained tables, you can control all the tables with a single CSS attribute in an external CSS text file.

On the other hand if you had 100 pages and each page needs a different layout you can use "in-line styles" (as shown above) to custom design each table.

Last of all..... will I need to repeat this code for each table tag in
the document
Yes. Unless you have a CSS declaration named TABLE, then that declaration will instruct all the tables in all the linked documents.

 or does the document assume the command applies for all
instances of tables on the page?
CSS stands for Cascading Style Sheets. The Cascading term means that most CSS declarations are inherited downward within your documents if you are using an external Style Sheet text documents and it is linked into all your pages.

The power of CSS is in how you use it in all your HTML documents.
The first order of precedence is the External CSS text file linked into your HTML documents. The second order of precedence are the CSS declarations inserted into the <Head> of each HTML document. The third order of precedence is in-line CSS declarations inserted into the HTML formatting tags like <Table>.


For what its worth you can copy one of your existing HTML documents to a new filename and play with CSS on that copied file, using SM to proof your coding.

Michael G

--
Armadillo Web Development
www.armadilloweb.com

Cell: 903.244.3644

Opening your Door to Opportunity
and inviting the world to walk through.

Character is doing the right thing...
Even when no one is watching...

_______________________________________________
support-seamonkey mailing list
[email protected]
https://lists.mozilla.org/listinfo/support-seamonkey

Reply via email to