Tribeless Nomad (tribelessnomad) wrote in lj_biz,
Tribeless Nomad

lj_doc: classic.xsl stylesheet for protocol docs

I've uploaded two more files for use with the XML version of LiveJournal's protocol documentation. They are:
  • classic.xsl -- a stylesheet written to emulate the style of the existing HTML version.
  • classic.htm -- a very small page of JScript that instructs Internet Explorer 5 to display the XML documents using the new stylesheet.
Please note that if you're not using IE5, you're on your own in trying to use other software to follow what I'm doing. However, if you trace any problems to the documents I'm posting, I'd like to know. I understand that once this documentation system has been set up, server-side processing will allow the XML documents on LJ's server to be viewed by anyone with an HTML browser.

When you load classic.htm into IE5, one significant problem is apparent: the block of text that should appear as
instead appears as
because whitespace is being stripped. It's fairly well known -- and a cause of much annoyance -- that IE5's XML document object strips whitespace by default. I think the solution is to set
xml.preserveWhiteSpace = true;
but when I try to do this (you can see the instruction commented out in the source), the file doesn't load.

I assume I'll learn more about that when I have chance to look into the resulting status codes. Right now, however, I'm more interested in writing another stylesheet, to display the metadata that I've added to the XML files.

  • Post a new comment


    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded