Translating Search appliance results

jgdoke
Posts: 167
Joined: Wed Jul 14, 2004 10:52 am

Translating Search appliance results

Post by jgdoke »

I am trying to insert the translated words in the result. I find some of them in the XSL output but not all. Is there a more complete file?

Has someone already done this?


Search for this:
11 through 20 of 12,846 matching documents,
best matches first.
sort by date
<<previous
Page: 1 2 3 4 5 6 7 8 9 10
next>>
No documents match the query.
Did you mean:
User avatar
mark
Site Admin
Posts: 5519
Joined: Tue Apr 25, 2000 6:56 pm

Translating Search appliance results

Post by mark »

In the XSL:
"Search for this:" literally

11 through 20 of 12,846 matching documents,
best matches first.
sort by date
<xsl:value-of select="Start"/> through <xsl:text/>
<xsl:value-of select="End"/> of <xsl:text/>
<xsl:value-of select="Total"/>
<xsl:value-of select="CurOrder"/>
<xsl:text>&#160;&#160;&#160;</xsl:text>
<xsl:element name="a">
<xsl:attribute name="href">
<xsl:value-of select="OrderLink"/>
</xsl:attribute>
<xsl:value-of select="OrderType"/>
</xsl:element>

"<< previous" literally

Page: 1 2 3 4 5 6 7 8 9 10
<xsl:for-each select="Pages">
<xsl:if test="position() = 1">
<xsl:text>Page:</xsl:text>
</xsl:if>
<xsl:text> </xsl:text>
<xsl:choose>
<xsl:when test="PageLink='NULL'">
<B><xsl:value-of select="PageNumber"/></B>
</xsl:when>
<xsl:otherwise>
<xsl:element name="a">
<xsl:attribute name="href">
<xsl:value-of select="PageLink"/>
</xsl:attribute>
<xsl:value-of select="PageNumber"/>
</xsl:element>
</xsl:otherwise>
</xsl:choose>
</xsl:for-each>

"next >>" literally

"No documents match the query."
<xsl:value-of select="QueryMessage"/>

"Did you mean:"
<xsl:value-of select="SpellPhrase"/>
jgdoke
Posts: 167
Joined: Wed Jul 14, 2004 10:52 am

Translating Search appliance results

Post by jgdoke »

I have found that I get errors if I use accented characters in the XML for instance:
English: (No documents match the query.)
Spanish: (Ningún documento coincide con la indagación.)

The code equivalents & #250; do work but I was wondering if there is an easier way..
User avatar
John
Site Admin
Posts: 2623
Joined: Mon Apr 24, 2000 3:18 pm
Location: Cleveland, OH

Translating Search appliance results

Post by John »

You need to use UTF-8 in the XSL rather than ISO-8859-1. Depending on your editor you may be able to set the encoding there.
John Turnbull
Thunderstone Software