ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> xsl-list
xsl-list
Re: [xsl] Looping over a CSV in XSL
by cutlass other posts by this author
Nov 19 2001 3:17PM messages near this date
[xsl] Looping over a CSV in XSL | [xsl] for loop in conditional statement
----- Original Message -----
From: "Khan, Amir" <amkhan@[...].com> 
>  I currently use the contains function and treat the list as a BIG string
but
>  this is very crude and not for problems e.g.
> 
>  List = "Fredrick, Aaron, john, peter"
>  I want to do a test in XSL e.g. if(inCSV(@forname))
> 
>  Where if @forename = "F" the match would fail (it currently doesn't as F
is
>  a subset of Fredrick) ;-(

your best best are

a) make xml instead of csv externally, if possible
b) use node-set extension, this is not part of XSLT but a common extension
found in most XSLT processors

http://www.idev.cz/DataConvert/csv2xml_en.html
here is a tool that does simple csv 2 xml conversion, i am sure that ther
are others out there.

cheers, jim fuller


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list
Thread:
Khan, Amir
cutlass

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved