SitePoint Sponsor

User Tag List

Results 1 to 2 of 2
  1. #1
    SitePoint Member
    Join Date
    Jan 2005
    Location
    Ottawa, ON
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    xslt -> use conditional processing or Xpath

    Hi:

    I'm having some difficulties getting my head around if I would use conditional processing or an Xpath query (or a more relevant approach) for the following (fragment of) xml:

    I want to match all unique dates for an action element , in order to build a result tree of its child nodes (all grouped by date/fileno). Any pointers in which direction to take this would go along way.

    Code:
      <content_part type="COMPMT">
        <title>1202 Continuation A NAD83</title>
        <action fileno="6405289" refid="1" date="25-APR-03 or 03-04-25" content_key="109875" remark_code="NMTEXT">
          <maint_verb>Add</maint_verb>
          <maint_remark>beacon Bn</maint_remark>
          <location>4825`02.3"N 07053`08.7"W </location>
          <ccg_ref>L2003021 DFO(6405289-01)</ccg_ref>
        </action>
        <action fileno="6500166" refid="1" date="28-NOV-03 or 03-11-28" content_key="109877" remark_code="NMTEXT">
          <maint_verb>Amend</maint_verb>
          <maint_remark>contour label 18 to read 18.3</maint_remark>
          <location>4822`33.0"N 07042`30.0"W </location>
          <ccg_ref> DFO(6500166-01)</ccg_ref>
        </action>
        <action fileno="6406770" refid="1" date="03-DEC-04 or 04-12-03" content_key="109878" remark_code="NMTEXT">
          <maint_verb>Delete</maint_verb>
          <maint_remark>depth of 0 metre 3 decimetres</maint_remark>
          <location>4821`16.6"N 07052`00.3"W </location>
          <ccg_ref> DFO(6406770-01)</ccg_ref>
        </action>
        <action fileno="6406770" refid="2" date="03-DEC-04 or 04-12-03" content_key="109878" remark_code="NMTEXT">
          <maint_verb>Delete</maint_verb>
          <maint_remark>depth of 11 metres 9 decimetres</maint_remark>
          <location>4821`14.3"N 07052`01.7"W </location>
          <ccg_ref> DFO(6406770-02)</ccg_ref>
      </content_part>
    Last edited by theopuskin; Jan 10, 2005 at 22:42. Reason: mispelled xls - meant xslt

  2. #2
    SitePoint Member
    Join Date
    Jan 2005
    Location
    Ottawa, ON
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    re:

    This is (a) solution to the above question.

    http://www.jenitennison.com/xslt/gro...muenchian.html


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •