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

RE: Bibliography References

Subject: RE: Bibliography References
From: "Mark Shellenberger" <mshellenberger@xxxxxxxxx>
Date: Wed, 13 Sep 2006 18:19:49 -0400
mark shellenberger
...tentatively dips his virtual finger in the listserv.

I have an XSLT 1.0 solution.

    <xsl:template match="bibliography"/>
    <xsl:template match="bibref">
        <xsl:variable name="xref" select="@xref"/>
        <xsl:for-each select="//bibliography/bibliomixed">
          <xsl:if test="@id = $xref">
            <xsl:value-of select="count(preceding-sibling::bibliomixed)+1"/>
          </xsl:if>
       </xsl:for-each>
    </xsl:template>
</xsl:stylesheet>

I am sure there is a more XSLTish way of doing this and that there is some
super-fantabulous way of doing it in XSLT 2.0, but this works.  I can't wait
to see what others suggest.

--Mark

-----Original Message-----
From: siarom egrub [mailto:egrubs@xxxxxxxxx] 
Sent: Wednesday, September 13, 2006 5:17 PM
To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx
Subject:  Bibliography References

Hi All!

I am trying to output the following bibliography
references (<bibref...>) in following format. 

***This is the output that I want:***

Refer to References (1, 4, 5) for guidelines on
performing precision testing.

***The source file looks like this:***

<para>Refer to References (<bibref
xref="bib98861831"/>,<bibref
xref="bib98861816"/>,<bibref xref="bib988618273"/>)
for guidelines on performing precision testing.</para>

<bibliography><title>REFERENCES</title>
  <bibliomixed id="bib98861831">National
Committee...<booktitle>Fundamentals...</booktitle>...</bibliomixed>

  <bibliomixed id="bib98861814">National
Committee...</bibliomixed> 
  <bibliomixed id="bib98861870">National
Committee...</bibliomixed>
  <bibliomixed id="bib98861816">National
Committee...</bibliomixed> 
  <bibliomixed id="bib988618273">National Committee
for Clinical...</bibliomixed>
 </bibliography> 
  
 I think I may have to first check the "xref" value
against the "id" in bibliomixed for a match and then
count the bibliomixed location and output the
reference number. But how do I get started?
 
 Could someone give me a few pointers on how to
accomplish this task?
 
 Thanks in advance for your help!!

S.Egrub

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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.