Subject: Re: [xsl] Passing in parameter used in matching From: Jeni Tennison <jeni@xxxxxxxxxxxxxxxx> Date: Thu, 18 Oct 2001 16:26:44 +0100 |
Hi Katie, > One of my pages has a field that allows the user to enter a last > name and then click the "search" button. The results should display > all loans that have a borrower with a last name that matches the > criteria entered by the user (partial match). The name entered by > the user is passed as a parameter to the XSL stylesheet. With the > XSL below, the "No results were found" is displayed on the search > results page, even when I enter a name (or partial name) that > matches one of the borrower's last names in the XML. What am I doing > wrong? It's hard to tell. The path looks OK from the XML that you're provided. Are you sure that the parameter is being passed through to the stylesheet correctly? (Try printing out the parameter value on the generated page.) Also, try removing the predicate from the end of the path, to see whether it's managing to find any Borrower elements at all (let alone those with a specific LastName). I assume that here: > <xsl:when > test=\"ReturnResultSet/LoanSearchSet/Loan/LoanBorrowerSet/Borrower[contains(LastName, > $nameSearchValue)]\"> the \s before the "s were typos in the email and aren't present in the XSLT (if they were, then you should get a big error from the XSLT processor). Cheers, Jeni --- Jeni Tennison http://www.jenitennison.com/ XSL-List info and archive: http://www.mulberrytech.com/xsl/xsl-list
Current Thread |
---|
|
<- Previous | Index | Next -> |
---|---|---|
RE: [xsl] Passing in parameter used, Michael Kay | Thread | [xsl] Joining two XML-files, Jorge Bello |
Re: [xsl] Paging and Sorting, Jeni Tennison | Date | Re: [xsl] Generating numbering for , Thomas B. Passin |
Month |