This Message Forum is no longer in use

Please use the new Bravenet Help Forums FOUND HERE

General Forum
This Forum is Locked
Author
Comment
how to validate the HTML code on my webpage?

hello,
i use dreamweaver version 6 & file manager to create my site.
when i try to validate my code, it says many tags such as

, font etc are not acceptable.
bravenet adds a doctype declaration to my code that says
how should i validate my code & how can i ensure that code on my site are according to the declaration?

Re: how to validate the HTML code on my webpage?

You may have to get paid hosting and use a style sheet so you don't have to use the font tag.

Re: how to validate the HTML code on my webpage?

Go to this site: http://validator.w3.org/

Bennie...I validated your site.And you have a 100% mark bro!

Look at this:

Result: Passed validation
Address:
Modified: Sat Feb 25 17:24:16 2006
Server: Apachexxxxxxxx
Size: xxxxxx
Content-Type: text/html
Encoding: iso-8859-1
Doctype: XHTML 1.0 Strict
Root Namespace: http://www.w3.org/1999/xhtml

The document located at http://oconeescrc.com/ was checked and found to be valid XHTML 1.0 Strict.

Nice!

Re: how to validate the HTML code on my webpage?

Bennie's solution may be the best. But it is not the only one. I'm fairly certain the validator doesn't say "font tags are not acceptable", but something like "font tag not allowed here".

Using font tags can be a lot of hard work. The problem is that font is an inline element and cannot be used across a block-level element. If you have a font tag outside a table, for instance, you need to close it, then add new font tags for text inside the table. Even a


tag in a text defined by a font tag will give you errors.

Re: how to validate the HTML code on my webpage?

Looks like the majority of rk's errors are from the code Bravenet inserts. It must insert a doc type inside the body tag.

Re: how to validate the HTML code on my webpage?

thank you very much,
i understand that most of my errors are due to bravenet banner and some dynamic links in my page.
thank you again.

Re: Re: how to validate the HTML code on my webpage?

If you want your site certified as compliant then you cannot have third party code added dynamically as you do not control it. There are some trivial mistakes in some of the service codes, I don't know if they can be corrected using the Wizard but if you use any other editor then they are totally under your control.

Personally, as I am not after a W3C stamp on my site I only worry about my own content. If third party service and ad codes work then I leave them alone.

Re: Re: how to validate the HTML code on my webpage?

The W3C set the standards for what is and isn't HTML and their validators validate HTML against the particular DOCTYPE in the page itself (which is what the DOCTYPE is for). FONT used to be a valid tag last century before the introduction of stylesheets. Since HTML is now supposed to only define the content of the page leaving stylesheets to define how it looks the latest versions of HTML have disposed of a lot of tags that have nothing to do with content.

You can't change the code for the ads that are added to free hosted sites so free sites may never validate properly and hence may not display at all in some browsers.

All of the bravenet copy/paste code can be easily modified if required in order to get it to validate. Normally replacing & with & whereever it occurs is sufficient to fix the errors in that code.

Re: how to validate the HTML code on my webpage?

thanks all of you.
when i validate my code at http://validator.w3.org/,
it says...
there is no attribute "BORDERCOLOR".
< table bordercolor="#0000FF" border="3" cellspacing="4">

there is no attribute "COLOR".
< hr color="#0000FF">

what else should i use?

instead of font what code i should use to change color of any partcular piece of text. what code should i use in CSS? ( i use file manager now)

can i use Div tag to center text?

Re: Re: how to validate the HTML code on my webpage?

HTML defines your page content - NOT how it looks. How it looks is the job of the stylesheet commands.