<% $t->{'a'}{pre} = ''; $t->{'a'}{post} = ''; $t->{'a'}{showtag} = 1; my ($i, $j); $t->{'title'}{testcode} = sub { my $node = shift; if (findvalue('parent::section = true()', $node)) { $i++; $j = 0; $t->{'title'}{pre} = "

"; $t->{'title'}{post} = '

'; } elsif (findvalue('parent::subsection = true()', $node)) { $j++; $t->{'title'}{pre} = "

"; $t->{'title'}{post} = '

'; } else { $t->{'title'}{pre} = ''; $t->{'title'}{post} = ''; } return 1; }; $t->{'section'}{post} = '

'; $t->{'subsection'}{pre} = '

'; $t->{'subsection'}{post} = '

'; %> <%= apply_templates('/page/head/title') %>

<%= findvalue('/page/head/title/text()') %>

<% my $x = 0; foreach my $section (findnodes('/page/body/section')) { $x++; print "", findvalue('./title/text()', $section), "
\n"; my $y = 0; foreach my $subsect (findnodes('./subsection', $section)) { $y++; print " - ", findvalue('./title/text()', $subsect), "
\n"; } } %> <%= apply_templates('/page/body/section') %>
This page is copyright Fastnet Software Ltd, 2000. Contact Matt Sergeant for details and availability.
This page was generated by XPathScript, using the Apache XML Delivery Toolkit.