Jump to content
xisto Community
Sign in to follow this  
Lozbo

Xhtml Dtd can you set it up?

Recommended Posts

Can you set up the document type definition in order to create your own tags in XHTML? (Just as it happens with XML).I have been learning XML and DTD, and as i actually DO find it useful, i think its even more useful the fact that a language (like HTML) already strongly accepted, has its own structures defined. Its just sometimes you need to add a little adjustment here and there. So i ask if theres a way to define this in XHTML, your structures of tags and attributes and all that. I already know a coupple of sites which teach xhtml, but just have not found what i was looking for. Thanks...

Share this post


Link to post
Share on other sites

do you mean this<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"><!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN"> thats the only way you would identify the xhtml document to be checked for syntax.

Share this post


Link to post
Share on other sites

do you mean this

 

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN">

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN">

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Frameset//EN">

thats the only way you would identify the xhtml document to be checked for syntax.

185630[/snapback]

i mean something like this:

<?xml version="1.0"?><!DOCTYPE note [  <!ELEMENT message(to,from,subject,body)>  <!ELEMENT to      (#PCDATA)>  <!ELEMENT from    (#PCDATA)>  <!ELEMENT subject(#PCDATA)>  <!ELEMENT body    (#PCDATA)>]>

So an example xml document for that given DTD would be:

<message>  <to>Saint Michael</to>  <from>Lozbo</from>  <subject>Sig Request</subject>  <body>Your sigs rock dude! I have already made a sig request in the right forum, hope some one as good as you has the time to do me that favor! </body></message>

But something like this, highly customizable for XHTML...

Share this post


Link to post
Share on other sites

You could create custom DTDs and host them on your server, then point your pages to use that DTD.. But then most validators wont validate for you cuz you're not using an approved DTD...Besides the fact that creating a new DTD just to validate new tags in an XHTML document is rather pointless, as the extensibility of it is good enough as it is..Anyway, try google searching for "Custom DTDs" and stuff..

Share this post


Link to post
Share on other sites

You could create custom DTDs and host them on your server, then point your pages to use that DTD..  But then most validators wont validate for you cuz you're not using an approved DTD...

 

Besides the fact that creating a new DTD just to validate new tags in an XHTML document is rather pointless, as the extensibility of it is good enough as it is..

 

Anyway, try google searching for "Custom DTDs" and stuff..

185772[/snapback]


That's the only way I could think of doing it...you might be able to create your custom DTD and add the XHTML DTD you want by just adding that DTD to your custom DTD. You can get all of the W3C DTDs at http://www.w3.org/

Share this post


Link to post
Share on other sites

Besides the fact that creating a new DTD just to validate new tags in an XHTML document is rather pointless, as the extensibility of it is good enough as it is..

Yes, i think you are right. Its just, as im new to dtd, schema and xml, i was just wondering if that was possible, and maybe thinking that it would be even more extensible or something. Thanks.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×
×
  • Create New...

Important Information

Terms of Use | Privacy Policy | Guidelines | We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.