tags:

views:

10

answers:

1

Hi

I am wondering if there is any chance to create a wildcard attribute list in xhtml. E.g.

   ?><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" [
      <!ATTLIST a tooltip CDATA #IMPLIED>
      <!ATTLIST a tooltip-align (top|bottom|right|left) #IMPLIED>
    ]>

Instead of "a" I would like to add these two attributes to all elements. Any idea? Thanks

+1  A: 

No. The XHTML DTD works around this with entity declarations, something like this (simplified):

<!ENTITY % coreattrs
 "id          ID             #IMPLIED
  class       CDATA          #IMPLIED
  style       %StyleSheet;   #IMPLIED
  title       %Text;         #IMPLIED"
  >

<!ELEMENT a %a.content;>
<!ATTLIST a
  %coreattrs;
  href        %URI;          #IMPLIED
  ... etcetera ...
  >
Thomas