Re: HTML is a formatting/UI language was: RE: Formatting Objects considered harmful

Subject: Re: HTML is a formatting/UI language was: RE: Formatting Objects considered harmful
From: Håkon Wium Lie <howcome@xxxxxxxxxxxxxxxxx>
Date: Mon, 19 Apr 1999 22:06:04 +0200 (MET DST)
[Thanks for changing the subject. We're moving towards the periphery
of this mailing list]

Jonathan Borden wrote:

 > 	I have been developing a Web based electronic medical records/workflow
 > system. Here is an example document fragment:
 > 
 > <person xmlns="urn:hl7" UID=".." SSN="...">
 > 	<n>
 > 	   <FirstName>John</FirstName>
 > 	   <LastName>Smith</LastName>
 > 	</n>
 > 	<a type="home"><Address1>... ...</a>
 > 	<DOB dt:dt="iso...">...
 > 	<insurance ID="...">
 > 		<business role="Insuror">...</business>
 > 		...
 > 	</insurance>
 > 	<person role="Provider">...
 > 	<person role="EmergencyContact"> ...
 > 	<diagnosis CPT="...">...
 > 	<medication ...>
 > 
 > 	How would you render this in HTML+CSS, and maintain the 'semantic' content?

Here's one example:

  <div class="person" xmlns="urn:hl7" UID=".." SSN="...">
 	<div class="n">
 	   <span class="FirstName">John</SPAN>
 	   <span class="LastName">Smith</SPAN>
 	</div>
 	<div class="a" type="home"><SPAN CLASS="Address1">... ...</DIV>
 	<span class="DOB" dt:dt="iso...">...
 	<span class="insurance" ID="...">
 		<span class="business" role="Insuror">...</SPAN>
 		...
 	</span>
 	<div class="person" role="Provider">...
 	<div class="person" role="EmergencyContact"> ...
 	<div class="diagnosis" CPT="...">...
 	<div class="medication" ...>

I understand if you don't want to use this format internally, but when
shipping across the Web, my example can be shown in 100 million
browsers -- including aural ones -- yours can't. And they both contain
your original semantics. You can programatically convert my document
back to yours.

If I had known about the semantics of your tags, I could have done a
better job of converting into XHTML tags. Most likely, there are
better alternatives than DIV and SPAN, but since I don't know the
semantics of your DTD etc. I'm sure you see the irony :-)

[The above conversion is slightly simplified. If you insist on valid
documents, not only well-formed ones, you will have to add more
elements to represent the non-XHTML attributes. Also, you may want to
insulate the ID attribute on the "insurance" element to avoid name
conflicts. The same would be the case if you happened to use an
attribute named "class" in you internal DTD]

 > My point is that XML is compared not to HTML
 > rather SGML, and XHTML is merely an XML document type, hence your call to
 > transmit XHTML rather than 'arbitrary' XML is merely a call to perform
 > translation on the server rather than the client. This is wasteful of server
 > resources and severly limits the ability of sophisticated client side
 > processing.

There is a small cost involved in the server-side conversion, yes. But
you can still do the client side processing since all your data is
still there.

What you gain is accessibility. 

-h&kon

Håkon Wium Lie             http://www.operasoftware.com/people/howcome
howcome@xxxxxxxxxxxxxxxxx                      simply a better browser



 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list


Current Thread