> For the complete documentation index, see [llms.txt](https://support.morozovpimnev.ru/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://support.morozovpimnev.ru/multiregion/poisk.md).

# Поиск

В связи с особенностями системы, для главной страницы при поиске выводится не название страницы, как у других, а title, но т.к. в title могут присутствовать meta подстановки, то вывод заголовка выглядит не очень красивый, чтобы этого избежать нужно внести правки в XSL шаблон "Поиск", заменить template search\_page на представленный ниже

{% code fullWidth="true" %}

```html
<xsl:template match="search_page">
	    
	<xsl:variable name="title"><xsl:choose>
		<xsl:when test="structure[path='/']"><xsl:value-of select="structure/name"/></xsl:when>
		<xsl:otherwise><xsl:value-of select="title"/></xsl:otherwise>
	</xsl:choose></xsl:variable>
    
	<li>
		<a href="{url}"><xsl:value-of select="$title"/></a>
		<br/>
		<span class="description"><xsl:apply-templates select="url"/><xsl:text> · </xsl:text><xsl:value-of select="round(size div 1024)"/><xsl:text> Кб · </xsl:text><xsl:value-of select="date"/></span>
	</li>
</xsl:template>
```

{% endcode %}
