Re: [xsl] newbie question

Subject: Re: [xsl] newbie question
From: Aad Kamsteeg <a.kamsteeg@xxxxxxxxxxxxxxx>
Date: Fri, 30 Jul 2004 11:27:00 +0200
Try this:

<xsl:template match="link">
<xsl:when test="starts-with(., 'http://') or starts-with(., 'ftp://')">
<a href="{.}">text</a>

:-) Aad

Dionylon Briones wrote:

hello everyone,
i'm new to XSL and need help with this problem:

choose a link for the title, base on the following conditions:
 1. if the value of the link node has 'http://' string
 2. if there's no 'http://' string get the value of the link node that
contains 'ftp://' string

output should be: <a href="selected link">title</a>


<?xml version="1.0" encoding="ISO-8859-1" standalone="yes"?>
<link>invalid link</link>

-- ********************************************* Diderot Track bv - Consultants in Information

Phone: +31 (0) 70 3966304
Fax:   +31 (0) 70 3966305
Email: a.kamsteeg@xxxxxxxxxxxxxxx

Current Thread