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

S

SMH

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?
 
B

Beauregard T. Shagnasty

SMH said:
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
 
S

SMH

Beauregard T. Shagnasty said:
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."
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.
 
B

Beauregard T. Shagnasty

SMH said:
in alt.html:

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 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.
 

Ask a Question

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

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
473,764
Messages
2,569,564
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top