Is Align Attribute Valid for P Element in XHTML or not?

Discussion in 'HTML' started by SMH, Jun 14, 2008.

  1. SMH

    SMH Guest

    It seems that in even years the align attribute is allowed and then in odd
    years it's not.

    I am trying to use XHTML because I want to use MathML, and getting the
    DOCTYPE declaration and the 'html' element written properly is like trying
    to pull hen's teeth. Indeed I am copying the DOCTYPE and html and mathml
    elements into a page which does not render, but it renders on the page from
    which I copied the source! How does that (not) work?
    SMH, Jun 14, 2008
    #1
    1. Advertising

  2. SMH wrote:

    > It seems that in even years the align attribute is allowed and then in
    > odd years it's not.


    Depends on whether or not you are Strict or Transitional.

    <p class="pcenter">This would be centered.</p>

    ..pcenter { text-align: center; }

    > I am trying to use XHTML because I want to use MathML, and getting the
    > DOCTYPE declaration and the 'html' element written properly is like
    > trying to pull hen's teeth. Indeed I am copying the DOCTYPE and html
    > and mathml elements into a page which does not render, but it renders
    > on the page from which I copied the source! How does that (not)
    > work?


    Are you using a proper mathml doctype?

    http://www.w3.org/QA/2002/04/valid-dtd-list.html

    <!DOCTYPE math SYSTEM
    "http://www.w3.org/Math/DTD/mathml1/mathml.dtd">

    ...for example

    --
    -bts
    -Friends don't let friends drive Windows
    Beauregard T. Shagnasty, Jun 14, 2008
    #2
    1. Advertising

  3. SMH

    SMH Guest

    "Beauregard T. Shagnasty" <> wrote in alt.html:

    > SMH wrote:
    >
    >> It seems that in even years the align attribute is allowed and then in
    >> odd years it's not.

    >
    > Depends on whether or not you are Strict or Transitional.
    >
    > <p class="pcenter">This would be centered.</p>
    >
    > .pcenter { text-align: center; }


    So with strict, no, right?
    With transitional, it's wink-wink, right?

    I suppose as strict as XHTML is---with all the required closing tags for
    all elements----then "deprecated" for an attribute or element really means
    "absolutely verboten."

    >
    >> I am trying to use XHTML because I want to use MathML, and getting the
    >> DOCTYPE declaration and the 'html' element written properly is like
    >> trying to pull hen's teeth. Indeed I am copying the DOCTYPE and html
    >> and mathml elements into a page which does not render, but it renders
    >> on the page from which I copied the source! How does that (not)
    >> work?

    >
    > Are you using a proper mathml doctype?
    >
    > http://www.w3.org/QA/2002/04/valid-dtd-list.html
    >
    > <!DOCTYPE math SYSTEM
    > "http://www.w3.org/Math/DTD/mathml1/mathml.dtd">
    >
    > ..for example


    I think this would be so IF I was only using MathML in the document.

    However, I am mixing (X)HTML and MathML together, and these mixed
    declarations are possible.

    The W3 Validation service is not being helpful.
    SMH, Jun 14, 2008
    #3
  4. SMH wrote:

    > "Beauregard T. Shagnasty" wrote in alt.html:
    >> SMH wrote:
    >>> It seems that in even years the align attribute is allowed and then
    >>> in odd years it's not.

    >>
    >> Depends on whether or not you are Strict or Transitional.
    >>
    >> <p class="pcenter">This would be centered.</p>
    >>
    >> .pcenter { text-align: center; }

    >
    > So with strict, no, right?
    > With transitional, it's wink-wink, right?


    Wink-wink. Transitional is to be used when you are .. well ..
    transitioning old legacy documents that use presentational code (such as
    "align right" within the HTML. For Strict, all presentation is supposed
    to be in the CSS. New pages are supposed to be Strict.

    > I suppose as strict as XHTML is---with all the required closing tags
    > for all elements----then "deprecated" for an attribute or element
    > really means "absolutely verboten."


    ...as far as validation is concerned, yes.

    >>> I am trying to use XHTML because I want to use MathML, and getting
    >>> the DOCTYPE declaration and the 'html' element written properly is
    >>> like trying to pull hen's teeth. Indeed I am copying the DOCTYPE
    >>> and html and mathml elements into a page which does not render, but
    >>> it renders on the page from which I copied the source! How does
    >>> that (not) work?

    >>
    >> Are you using a proper mathml doctype?
    >>
    >> http://www.w3.org/QA/2002/04/valid-dtd-list.html
    >>
    >> <!DOCTYPE math SYSTEM
    >> "http://www.w3.org/Math/DTD/mathml1/mathml.dtd">
    >>
    >> ..for example

    >
    > I think this would be so IF I was only using MathML in the document.


    Got a URL?

    > However, I am mixing (X)HTML and MathML together, and these mixed
    > declarations are possible.


    I don't really do MathML, but does it need XHTML? Why not HTML?

    See: http://tekrider.net/html/doctype.php

    > The W3 Validation service is not being helpful.


    It usually is, if you can interpret the error messages.

    --
    -bts
    -Friends don't let friends drive Windows
    Beauregard T. Shagnasty, Jun 14, 2008
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. anonymous
    Replies:
    1
    Views:
    5,925
  2. =?Utf-8?B?TWFyaw==?=
    Replies:
    4
    Views:
    619
    =?Utf-8?B?TWFyaw==?=
    Dec 14, 2006
  3. Radu
    Replies:
    2
    Views:
    1,326
  4. perspolis
    Replies:
    1
    Views:
    2,536
    Mark Rae
    Jan 23, 2007
  5. Joe Kovac
    Replies:
    2
    Views:
    923
    Joe Kovac
    May 2, 2007
Loading...

Share This Page