Skip to content

Instantly share code, notes, and snippets.

@Alhadis
Created March 13, 2024 12:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save Alhadis/f13d4bea109767149f4fc5125bd152c2 to your computer and use it in GitHub Desktop.
Save Alhadis/f13d4bea109767149f4fc5125bd152c2 to your computer and use it in GitHub Desktop.
Mixed-namespace XHTML example
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd" [
<!ENTITY ns_xhtml "http://www.w3.org/1999/xhtml">
<!ENTITY ns_cml "http://www.xml-cml.org/schema">
<!ENTITY ns_rdf "http://www.w3.org/1999/02/22-rdf-syntax-ns#">
]>
<html
xmlns="&ns_xhtml;"
xmlns:cml="&ns_cml;"
xmlns:rdf="&ns_rdf;"
><head>
<title>Mixed-namespace XHTML example</title>
</head>
<body>
<figure>
<figcaption>Chemical Markup Language (CML) example</figcaption>
<cml:molecule rdf:parseType="Literal" xmlns="&ns_cml;">
<formula concise="N H 3"/>
<name convention="trivial">ammonia</name>
<atomArray>
<atom elementType="N" x2="2.536900" y2="0.155000"/>
<atom elementType="H" x2="3.073900" y2="0.465000"/>
<atom elementType="H" x2="2.000000" y2="0.465000"/>
<atom elementType="H" x2="2.536900" y2="-0.465000"/>
</atomArray>
<bondArray>
<bond atomRefs2="a1 a2" order="1"/>
<bond atomRefs2="a1 a3" order="1"/>
<bond atomRefs2="a1 a4" order="1"/>
</bondArray>
</cml:molecule>
</figure>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment