[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Question about linking using ID/IDREF

Subject: Question about linking using ID/IDREF
From: Betty.Risher@xxxxxxxxxxxx
Date: Thu, 19 Apr 2001 08:05:05 -0600
aircraft jacking

Hi, I am just starting out using XSLT and have run into an issue.

I am trying to create a link between data in my xml that may occur anywhere in
the text.

 The text is defined with <refint> using an attribute of  "refid" to link  to
the attribute of "id".  I read earlier that I needed to use the XSLT style in
conjunction with a DTD.  I used XMLSPY to auto-generate a DTD.  Once I got my
coding in place, I tried to view this data in IE5.5 but it doesn't seem to work.
When I place my cursor over the link, in the info-line at the bottom of IE5.5 I
see, file:///c:/bjdir/amm/chap07.xml#T07-10-00-500-801-A.

 I'm at a loss as to what I could be doing incorrectly.  I would appreciate any
help in resolving this issue.

I've listed below examples of my XML,  my XSL coding and my DTD coding.

Thanks,

Betty Risher

XML Code example

<row>
  <entry align="LEFT">
    <unlist bulltype="NDASH" indent="1">
      <unlitem>
        <para>
           <refint origin="JEPP" refid="T07-10-00-500-801-A">TASK
07-10-00-500-801-A</refint>
        </para>
      </unlitem>
    </unlist>
  </entry>
  <entry align="LEFT">
    <para>Complete Aircraft Jacking</para>
  </entry>
</row>


<task chapnbr="07" confltr="A" efftext="ALL" effvect="001999" func="500" genattr
="CHAPNBR SECTNBR SUBJNBR ID EFFTEXT EFFVECT" id="T07-10-00-500-801-A" sectnbr="
10" seq="801" subjnbr="00">
  <title genattr="LBL" lbl="2.">Complete Aircraft Jacking</title>
    <tfmatr>
      <pretopic>


XSL Example coding


<xsl:template match="para/refint">
  <font color="blue">
      <a><xsl:attribute name="href">#<xsl:value-of select="@refid"/></
xsl:attribute><xsl:value-of select="id(@refid)"/><xsl:value-of select="."/></a>
  </font>
</xsl:template>


DTD Example

<!ELEMENT task (title, tfmatr, topic+, graphic*)>
<!ATTLIST task
  chapnbr CDATA #IMPLIED
  confltr CDATA #IMPLIED
  efftext CDATA #IMPLIED
  effvect CDATA #IMPLIED
  func CDATA #IMPLIED
  genattr CDATA #IMPLIED
  id ID #REQUIRED

<!ELEMENT refint (#PCDATA)>
<!ATTLIST refint
  origin (JEPP | MFR) #IMPLIED
  refid IDREF #REQUIRED
  genattr CDATA #IMPLIED
>



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


Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.