Hi all,
I'm trying to write a sitemap fragment which will execute a text search in a knowledge base product we are using.
The general scheme of the text search is this: 1) From my site, user requests search?text=foo+bar+baz 2) generator requests http:/example.com/interface?Action=CreateSession 3) ...parses the XML response to extract the Session ID element 4) ...requests http://example.com/interface?SessionID=123abc&Action=Search&Text=Search+terms
Does anyone know how I can code this up so it is a single map:match
entry? I know the following fragment is completely invalid, but it would be something like this:
<map:match pattern="search"> <!-- create a new search session --> <map:generate src="http:/example.com/interface?Action=CreateSession"/>
<!-- get session ID from resulting XML and return
it so we can use it for the next step-->
<map:transform src="extractsessionid.xsl">
<map:parameter name="extracted_sessionid"/>
</map:transform> <!-- Request another
page from the same server with URL consisting of session id
and search terms.
Yes, I know you can't really start another generator here. :)
-->
<map:generate
src="http:/example.com/interface?Action=Search">
<map:parameter
name="SessionID" value="{extracted_sessionid}" />
<map:parameter
name="Text" value="{request:search}" />
</map:generate><map:serialize type="xml"/> </map:match>
Maybe this is something that I can do with a regular xslt?
Many thanks in advance,
Jon
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
