How can I add new tags to the xhtml document without making the markup 'invalid'?
for eg:
instead of <span class="time"> I'd like to use <time>. Is this possible? because I've seen a facebook app do something like this.
You need to declare a new namespace for your invented elements:
<html xmlns:foo="urn:my-namespace">
...
<foo:time>...</foo:time>
or
<html>
...
<time xmlns="urn:my-namespace">...</time>
Of course, this isn't going to make an ounce of sense to your browser but I presume you have good reasons to want to do this.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With