RE: frameset and frame borders

Thank You for your prompt answer, Jukka.

What I ment by saying that 'the document does not validate anymore' was that
the document containing framesets validates perfectly without those
attributes. The page with the nonstandard attributes is available at:
http://www.excarnation.net/newroot by clicking Enter on the main page
(there's some Javascript and SSI so page has to be opened using that image
map link)

Actually I tried that custom DTD before mailing this list but was not able
to get it work with the W3C validator. Also making my own version of
frameset DTD felt like a hack to me. As you had noticed it seems to be the
validator not the custom DTD. However it will be taken care of now I
suppose.

Answer your question about why to use xhtml is that I'm tidying up the site
at http://www.excarnation.net (it really has to be done-). Also some new
cellphones support browsing xhtml sites and I'm guite exited about the
possibility to get testing it. Any 'real' reason as you said does not exists
other than mentioned above. However I like xhtml since it's much more
strictly specified than html.

Thank you again.

Best Regards:
	Aapo Romu

-----Original Message-----
From: www-validator-request@w3.org
[mailto:www-validator-request@w3.org]On Behalf Of Jukka K. Korpela
Sent: 20. toukokuuta 2004 23:11
To: www-validator@w3.org
Subject: Re: frameset and frame borders



On Thu, 20 May 2004, Aapo Romu wrote:

> I guess I'm not the only one with this problem and I also found some
answers
> from web authoring FAQ.

I presume you are referring specifically to
http://www.htmlhelp.com/faq/html/frames.html#frame-noborder
That FAQ is a fine resource, but a bit dusty. At present, IE 6 supports
frameset="0" in <frame> elements (as permitted by the Frameset DTD), so
by using such constructs you solve the problem in the great majority of
browsing situations. To be exact, that attribute does not remove the small
spacing between frames, so if this essential, you may wish to resort to
nonstandard markup.

> My problem is that I want to use frames without any
> borders or border spacing.

Generally, that increases the problems that frames cause. But on the
technical side, you are right in the observation:

> Solution is to use following attributes in
> frameset tag:
>
> <FRAMESET ... BORDER=0 FRAMEBORDER=0 FRAMESPACING=0>
>
> However after this has been done the document does not validate anymore
with
> xhtml-frameset.dtd.

"Anymore"? XHTML didn't change anything in this respect. It is not valid
for any DTD issued by the W3C.

> My question is that would it be possible to get some
> kind of transitional version of the DTD that would allow those attributes?

Transitional? Please don't obscure the situation by such ideas.
"Transitional" refers to very specific DTDs and they do not contain any
frame elements.

> Is there any known workaround for this problem?

As a _validation_ problem this is fairly simple. Your document currently
isn't valid. If you wish to use the attributes you mention, you simply
need to write a suitable DTD. In practice, you could take the HTML 4.01
Transitional DTD or the XHTML 1.0 Transitional DTD (have you really
got a _reason_ to use XHTML?) and modify it a bit. Note that the Frameset
DTDs effectively just set a parameter and "call" a Transitional DTD.
What you could do is this:
- create a copy of the Transitional DTD
- modify <!ENTITY % HTML.Version "-//W3C//DTD HTML 4.01 Transitional//EN"
  as desired (e.g. replace W3C by your name and change Transitional to
  Frames without borders :-))
- replace <!ENTITY % HTML.Frameset "IGNORE"> by
          <!ENTITY % HTML.Frameset "INCLUDE">
- the real change: inside the declaration that starts with
    <!ATTLIST FRAMESET
  add the lines
    border NUMBER #IMPLIED
    frameborder NUMBER #IMPLIED
    framespacing  NUMBER #IMPLIED

Then you would just use
<!DOCTYPE HTML SYSTEM "http://www.cs.tut.fi/~jkorpela/html/frames.dtd">
naturally replacing the URL by one of your own.

Oh, and you need a markup validator, such as
http://www.htmlhelp.com/tools/validator/

It seems that the W3C product isn't really a validator any more - when I
ask it to validate my (valid) SGML document using the DOCTYPE above,
it reports
This page is not Valid HTML 4.01 Transitional!
and then lists "the results of attempting to parse this document with an
SGML parser", something that isn't true at all - it has processed it as if
I had actually used the W3C HTML 4.01 Transitional DTD.

It seems that http://validator.w3.org cannot process any "custom DTDs"
(i.e., DTDs other than the fixed set of specific DTDs it has been
programmed to know) any more.

--
Jukka "Yucca" Korpela, http://www.cs.tut.fi/~jkorpela/

Received on Friday, 21 May 2004 08:12:39 UTC