{"id":151241,"date":"2012-11-07T13:52:05","date_gmt":"2012-11-07T09:52:05","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=151241"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=151241","title":{"rendered":"<span class=\"post_title\">\u0418\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 xslt-\u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u0432 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445<\/span>"},"content":{"rendered":"<div class=\"content html_format\">   \t\u0412 \u0441\u0442\u0430\u0442\u044c\u0435 \u0432\u044b \u043d\u0435 \u043d\u0430\u0439\u0434\u0451\u0442\u0435 \u0441\u0440\u0430\u0432\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0445 \u0442\u0435\u0441\u0442\u043e\u0432 \u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0442\u043e\u0440\u043e\u0432. \u0417\u0430\u0442\u043e \u043d\u0430\u0439\u0434\u0451\u0442\u0435 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e\u0431 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 xslt \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0442\u043e\u0440\u0430 \u043d\u0430 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445. \u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u044b \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432-\u0444\u0443\u043d\u043a\u0446\u0438\u0439, \u0441\u043f\u0440\u0430\u0432\u043e\u0447\u043d\u0438\u043a\u043e\u0432.<\/p>\n<h4>1. \u0421\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0430 \u043f\u0440\u043e\u0435\u043a\u0442\u0430<\/h4>\n<p>  \u041e\u0431\u044b\u0447\u043d\u043e \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0441\u0430\u0439\u0442\u0430 \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u0438\u0437 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u043e\u0431\u0449\u0438\u0445 \u0431\u043b\u043e\u043a\u043e\u0432 (\u043c\u0435\u043d\u044e, \u0444\u0443\u0442\u0435\u0440, &#8230;) \u0438 \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u043d\u043e\u0439 \u0447\u0430\u0441\u0442\u0438, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u0434\u043b\u044f \u043e\u0431\u0449\u043d\u043e\u0441\u0442\u0438 \u0431\u0443\u0434\u0435\u043c \u043d\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u043c \u0431\u043b\u043e\u043a\u043e\u043c. \u0412\u0441\u0435 \u044d\u0442\u0438 \u0431\u043b\u043e\u043a\u0438 \u0440\u0430\u0437\u043c\u0435\u0449\u0430\u044e\u0442\u0441\u044f \u0432\u043d\u0443\u0442\u0440\u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0438\u043d\u0434\u0435\u043a\u0441\u043d\u043e\u0433\u043e \u0448\u0430\u0431\u043b\u043e\u043d\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0437\u043d\u0430\u0435\u0442 \u0432 \u043a\u0430\u043a\u043e\u043c \u043c\u0435\u0441\u0442\u0435 \u043a\u0430\u043a\u043e\u0439 \u0431\u043b\u043e\u043a \u043e\u0442\u043e\u0431\u0440\u0430\u0437\u0438\u0442\u044c: \u043c\u0435\u043d\u044e \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u0432\u0432\u0435\u0440\u0445\u0443, \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0431\u043b\u043e\u043a \u0432 \u0446\u0435\u043d\u0442\u0440\u0435, \u0430 \u0444\u0443\u0442\u0435\u0440 \u0432\u043d\u0438\u0437\u0443.<\/p>\n<p>  \u041f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0443  <\/p>\n<pre><code class=\"bash\">\/themes - \u0437\u0434\u0435\u0441\u044c \u0440\u0430\u043f\u043e\u043b\u0430\u0433\u0430\u044e\u0442\u0441\u044f \u0432\u0441\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u044b \/themes\/index\/main.xsl - \u0438\u043d\u0434\u0435\u043a\u0441\u043d\u044b\u0439 \u0448\u0430\u0431\u043b\u043e\u043d \/themes\/models\/user.xsl - \u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u0442\u043d\u043e\u0441\u044f\u0442\u0441\u044f \u043a \u043c\u043e\u0434\u0435\u043b\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \/themes\/inc\/functions.xsl - \u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u044b-\u0444\u0443\u043d\u043a\u0446\u0438\u0438 \/themes\/blocks\/footer.xsl - \u0448\u0430\u0431\u043b\u043e\u043d \u0444\u0443\u0442\u0435\u0440\u0430 \/themes\/blocks\/menu.xsl - \u0448\u0430\u0431\u043b\u043e\u043d \u043c\u0435\u043d\u044e \/themes\/cabinet\/main.xsl - \u0448\u0430\u0431\u043b\u043e\u043d \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0433\u043e \u0431\u043b\u043e\u043a\u0430 \u0433\u043b\u0430\u0432\u043d\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043a\u0430\u0431\u0438\u043d\u0435\u0442\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f <\/code><\/pre>\n<p>  \u041a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 \u0433\u043b\u0430\u0432\u043d\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043a\u0430\u0431\u0438\u043d\u0435\u0442\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<ol>\n<li>\u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 \u0434\u0430\u043d\u043d\u044b\u0435 \u0434\u043b\u044f \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0433\u043e \u0431\u043b\u043e\u043a\u0430, \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u0442 \u0438\u0445 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \/themes\/cabinet\/main.xsl \u0438 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 (\u0433\u043e\u0442\u043e\u0432\u044b\u0439 html) \u043f\u043e\u043c\u0435\u0449\u0430\u0435\u0442 \u0432 \u0438\u0442\u043e\u0433\u043e\u0432\u044b\u0439 xml<\/li>\n<li>\u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u043e \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u0442 \u0434\u0430\u043d\u043d\u044b\u0435 \u0434\u043b\u044f \u0434\u0440\u0443\u0433\u0438\u0445 \u0431\u043b\u043e\u043a\u043e\u0432 (\u043c\u0435\u043d\u044e, \u0444\u0443\u0442\u0435\u0440) \u0438 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043f\u043e\u043c\u0435\u0449\u0430\u0435\u0442 \u0432 xml<\/li>\n<li>\u0438\u0442\u043e\u0433\u043e\u0432\u044b\u0439 xml, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u043d\u0430\u0445\u043e\u0434\u044f\u0442\u0441\u044f \u0434\u0430\u043d\u043d\u044b\u0435 \u0432\u0441\u0435\u0445 \u0431\u043b\u043e\u043a\u043e\u0432, \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0438\u043d\u0434\u0435\u043a\u0441\u043d\u043e\u0433\u043e \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \/themes\/index\/main.xsl \u0438 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043e\u0442\u0434\u0430\u0451\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e.<\/li>\n<\/ol>\n<p>  <a name=\"habracut\"><\/a><br \/>  \u0418\u043d\u0434\u0435\u043a\u0441\u043d\u044b\u0439 \u0448\u0430\u0431\u043b\u043e\u043d \/themes\/index\/main.xsl \u043c\u043e\u0436\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<pre><code class=\"xml\">&lt;xsl:template match=&quot;page&quot;&gt;        &lt;head&gt;         &lt;title&gt;&lt;xsl:value-of select=&quot;title&quot; \/&gt;&lt;\/title&gt;     &lt;\/head&gt;     &lt;body&gt;                 &lt;div class=&quot;page-container&quot;&gt;             &lt;xsl:value-of select=&quot;blocks\/menu_top\/html&quot; disable-output-escaping=&quot;yes&quot;\/&gt;                         &lt;div class=&quot;main&quot;&gt;                          &lt;xsl:value-of select=&quot;blocks\/content\/html&quot; disable-output-escaping=&quot;yes&quot;\/&gt;             &lt;\/div&gt;                         &lt;xsl:value-of select=&quot;blocks\/footer\/html&quot; disable-output-escaping=&quot;yes&quot;\/&gt;         &lt;\/div&gt;     &lt;\/body&gt; &lt;\/xsl:template&gt; <\/code><\/pre>\n<h4>2. \u0418\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u044b<\/h4>\n<p>  \u0428\u0430\u0431\u043b\u043e\u043d xslt \u043f\u0440\u0438\u043d\u0438\u043c\u0430\u0435\u0442 \u0434\u0430\u043d\u043d\u044b\u0435 \u0432 \u0432\u0438\u0434\u0435 xml-\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442\u0430. \u042d\u0442\u043e \u0443\u0434\u043e\u0431\u043d\u043e \u0442\u0435\u043c, \u0447\u0442\u043e \u043c\u044b \u043c\u043e\u0436\u0435\u043c \u043e\u043f\u0435\u0440\u0438\u0440\u043e\u0432\u0430\u0442\u044c \u0446\u0435\u043b\u044b\u043c\u0438 \u0443\u0437\u043b\u0430\u043c\u0438. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \u0434\u043b\u044f \u0432\u044b\u0432\u043e\u0434\u0430 \u0438\u043c\u0435\u043d\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0443 \u043d\u0430\u0441 \u043c\u043e\u0436\u0435\u0442 \u0431\u044b\u0442\u044c \u0442\u0430\u043a\u043e\u0439 \u0448\u0430\u0431\u043b\u043e\u043d  <\/p>\n<pre><code class=\"xml\">&lt;xsl:template name=&quot;inc_show_user&quot;&gt;     &lt;xsl:param name=&quot;user&quot;\/&gt;     &lt;img src=&quot;\/img\/{$user\/userpic}.png&quot;\/&gt;     &lt;xsl:value-of select=&quot;concat($user\/first_name, ' ', $user\/last_name)&quot;\/&gt; &lt;\/xsl:template&gt; <\/code><\/pre>\n<p>\u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0440\u0430\u0441\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u0442\u0441\u044f \u0432 \u0444\u0430\u0439\u043b\u0435 \/themes\/models\/user.xsl.<\/p>\n<p>  \u041c\u044b \u043c\u043e\u0436\u0435\u043c \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u044d\u0442\u043e\u0442 \u0448\u0430\u0431\u043b\u043e\u043d \u043a\u0430\u043a \u0434\u043b\u044f \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0442\u0435\u043a\u0443\u0449\u0435\u0433\u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f  <\/p>\n<pre><code class=\"xml\">&lt;xsl:call-template name=&quot;inc_show_user&quot;&gt;     &lt;xsl:with-param name=&quot;user&quot; select=&quot;\/*\/cur_user&quot;\/&gt; &lt;\/xsl:call-template&gt; <\/code><\/pre>\n<p>  \u0442\u0430\u043a \u0438 \u0434\u043b\u044f \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0441\u043f\u0438\u0441\u043a\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439  <\/p>\n<pre><code class=\"xml\">&lt;xsl:for-each select=&quot;users\/item&quot;&gt;     &lt;xsl:call-template name=&quot;inc_show_user&quot;&gt;         &lt;xsl:with-param name=&quot;user&quot; select=&quot;.&quot;\/&gt;     &lt;\/xsl:call-template&gt;             &lt;\/xsl:for-each&gt; <\/code><\/pre>\n<p>  \u0422\u0430\u043a\u043e\u0435 \u0435\u0434\u0438\u043d\u0441\u0442\u0432\u043e \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044f \u0441\u0443\u0449\u043d\u043e\u0441\u0442\u0435\u0439 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0431\u044b\u0441\u0442\u0440\u043e \u0438\u0437\u043c\u0435\u043d\u044f\u0442\u044c \u0438\u0445 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u0435. \u041a\u043e\u043d\u0435\u0447\u043d\u043e \u043d\u0435 \u0443 \u0432\u0441\u0435\u0445 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439 \u0435\u0441\u0442\u044c \u043a\u0430\u0440\u0442\u0438\u043d\u043a\u0430, \u0430 \u0437\u043d\u0430\u0447\u0438\u0442 \u0438 \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u044c \u0435\u0451 \u043d\u0443\u0436\u043d\u043e \u043d\u0435 \u0434\u043b\u044f \u0432\u0441\u0435\u0445  <\/p>\n<pre><code class=\"xml\">&lt;xsl:template name=&quot;inc_show_user&quot;&gt;     &lt;xsl:param name=&quot;user&quot;\/&gt;     &lt;xsl:choose&gt;         &lt;xsl:when test=&quot;$user\/userpic&gt;0&quot;&gt;             &lt;img src=&quot;\/img\/{$user\/userpic}.png&quot;\/&gt;                 &lt;\/xsl:when&gt;         &lt;xsl:otherwise&gt;             &lt;img src=&quot;\/img\/default.png&quot;\/&gt;         &lt;\/xsl:otherwise&gt;     &lt;\/xsl:choose&gt;         &lt;xsl:value-of select=&quot;concat($user\/first_name, ' ', $user\/last_name)&quot;\/&gt; &lt;\/xsl:template&gt; <\/code><\/pre>\n<h4>3. \u0418\u043c\u043f\u043e\u0440\u0442 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432<\/h4>\n<p>  \u0414\u043b\u044f \u0442\u043e\u0433\u043e \u0447\u0442\u043e\u0431\u044b \u0432 \u0448\u0430\u0431\u043b\u043e\u043d\u0435 \u0431\u043b\u043e\u043a\u0430 \u0438\u043c\u0435\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f \u043a \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0435\u043d\u0438\u044e \u0441\u0443\u0449\u043d\u043e\u0441\u0442\u0438 \u00ab\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c\u00bb \u043c\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c \u0444\u0430\u0439\u043b \/themes\/models\/user.xsl. <br \/>  \u0414\u043b\u044f \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \/themes\/cabinet\/main.xsl \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u0442\u0430\u043a  <\/p>\n<pre><code class=\"xml\">&lt;xsl:import href=&quot;..\/models\/user.xsl&quot;\/&gt; <\/code><\/pre>\n<p>(xsl:import \u0434\u043e\u043b\u0436\u0435\u043d \u043e\u043f\u0438\u0441\u044b\u0432\u0430\u0442\u044c\u0441\u044f \u0441\u0440\u0430\u0437\u0443 \u043f\u043e\u0441\u043b\u0435 xsl:stylesheet)<\/p>\n<h4>4. \u041d\u0438 \u0441\u0442\u0440\u043e\u0447\u043a\u0438 php-\u043a\u043e\u0434\u0430 \u0432 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u0438<\/h4>\n<p>  \u041f\u0430\u0442\u0435\u0440\u043d MVC \u043f\u0440\u0435\u0434\u043f\u043e\u043b\u0430\u0433\u0430\u0435\u0442 \u0440\u0430\u0437\u0434\u0435\u043b\u0435\u043d\u0438\u0435 \u043c\u043e\u0434\u0435\u043b\u0438, \u043b\u043e\u0433\u0438\u043a\u0438 \u0438 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u044f. \u041b\u043e\u0433\u0438\u043a\u0430 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u044f \u0437\u0430\u043f\u0440\u0430\u0448\u0438\u0432\u0430\u0435\u0442 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0443 \u043c\u043e\u0434\u0435\u043b\u0438 \u0438 \u043f\u0435\u0440\u0435\u0434\u0430\u0451\u0442 \u0438\u0445 \u0432 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u0435. \u041f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u0435 \u0434\u043e\u043b\u0436\u043d\u043e \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0435 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0434\u0430\u043d\u043d\u044b\u0445, \u0447\u0442\u043e\u0431\u044b \u0438\u0445 \u043e\u0442\u043e\u0431\u0440\u0430\u0437\u0438\u0442\u044c \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e. \u0422.\u0435. \u0432 \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u0438 \u043c\u044b \u0434\u043e\u043b\u0436\u043d\u044b \u0442\u043e\u043b\u044c\u043a\u043e \u0432\u044b\u0432\u0435\u0441\u0442\u0438 \u0438\u0445 \u0438 \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u044b \u043a\u0430\u043a-\u043b\u0438\u0431\u043e \u0435\u0449\u0451 \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u043e\u0432\u044b\u0432\u0430\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0435. \u041c\u044b \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c \u0438\u043c\u044f \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u043f\u043e \u0435\u0433\u043e id, \u043d\u0435 \u0434\u043e\u043b\u0436\u043d\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c \u0442\u0435\u043a\u0443\u0449\u0435\u0435 \u0432\u0440\u0435\u043c\u044f, \u0438 \u0442.\u0434. \u0432\u0441\u0435 \u044d\u0442\u0438 \u0434\u0430\u043d\u043d\u044b\u0435 \u0443\u0436\u0435 \u0434\u043e\u043b\u0436\u043d\u044b \u0431\u044b\u0442\u044c \u0434\u043e\u0441\u0442\u0443\u043f\u043d\u044b \u0434\u043b\u044f \u043f\u0440\u0435\u0434\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u0438\u044f. \u0415\u0441\u043b\u0438 \u043a\u0430\u043a\u0438\u0445-\u043b\u0438\u0431\u043e \u0434\u0430\u043d\u043d\u044b\u0445 \u043d\u0435 \u0445\u0432\u0430\u0442\u0430\u0435\u0442, \u0437\u043d\u0430\u0447\u0438\u0442 \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 \u0434\u043e\u043b\u0436\u0435\u043d \u0438\u0445 \u043f\u0440\u0435\u0434\u043e\u0441\u0442\u0430\u0432\u0438\u0442\u044c.<\/p>\n<p>  Xslt \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u0434\u0438\u0442\u044c \u043f\u0440\u043e\u0441\u0442\u0435\u0439\u0448\u0438\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438 \u0441 \u0434\u0430\u043d\u043d\u044b\u043c\u0438: \u0441\u0440\u0430\u0432\u043d\u0435\u043d\u0438\u0435, \u043f\u043e\u0434\u0441\u0447\u0451\u0442 \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u0430, \u0441\u043e\u0440\u0442\u0438\u0440\u043e\u0432\u043a\u0430, \u0444\u043e\u0440\u043c\u0430\u0442\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u0435 \u0447\u0438\u0441\u0435\u043b, \u043e\u043a\u0440\u0443\u0433\u043b\u0435\u043d\u0438\u0435, \u0430\u0440\u0438\u0444\u043c\u0435\u0442\u0438\u0447\u0435\u0441\u043a\u0438\u0435 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438, \u043a\u043e\u043d\u043a\u0430\u0442\u0435\u043d\u0430\u0446\u0438\u044f,\u2026 \u041a\u0430\u0437\u0430\u043b\u043e\u0441\u044c \u0431\u044b, \u0447\u0442\u043e \u044d\u0442\u043e \u043f\u0440\u043e\u0442\u0438\u0432\u043e\u0440\u0435\u0447\u0438\u0442 \u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0435\u043c\u0443 \u0430\u0431\u0437\u0430\u0446\u0443. \u041d\u043e \u043f\u043e\u0437\u0432\u043e\u043b\u044c\u0442\u0435 \u0437\u0430\u043c\u0435\u0442\u0438\u0442\u044c, \u0447\u0442\u043e \u0432 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0435 \u0432\u0441\u0435\u0445 \u044d\u0442\u0438\u0445 \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0439 \u043c\u044b \u043d\u0435 \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u043d\u043e\u0432\u044b\u0445 \u0434\u0430\u043d\u043d\u044b\u0445, \u0430 \u043b\u0438\u0448\u044c \u043f\u0440\u0435\u043e\u0431\u0440\u0430\u0437\u0443\u0435\u043c \u0438\u043c\u0435\u044e\u0449\u0438\u0435\u0441\u044f \u0434\u0430\u043d\u043d\u044b\u0435.<\/p>\n<p>  \u041d\u0435 \u0432\u0441\u0435\u0433\u0434\u0430 \u0435\u0441\u0442\u044c \u0432\u0441\u0435 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0435 \u0441\u0440\u0435\u0434\u0441\u0442\u0432\u0430 \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e\u0433\u043e \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442\u0430. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440, \u0432\u044b\u0432\u043e\u0434 \u043e\u043a\u043e\u043d\u0447\u0430\u043d\u0438\u044f \u0434\u043b\u044f \u0447\u0438\u0441\u043b\u0430. \u0414\u0443\u043c\u0430\u044e \u0443 \u043c\u043d\u043e\u0433\u0438\u0445 \u0435\u0441\u0442\u044c \u043f\u043e\u0434\u043e\u0431\u043d\u0430\u044f \u0444\u0443\u043d\u043a\u0446\u0438\u044f  <\/p>\n<pre><code class=\"php\">function str_plural_form($n, $form1='\u0448\u0442\u0443\u043a\u0430', $form2='\u0448\u0442\u0443\u043a\u0438', $form5='\u0448\u0442\u0443\u043a'){   $lastN=$num%10;   $lastT=$num%100;   if($lastT&gt;=10 && $lastT&lt;=20){     return $form5;   }   switch ($lastN){     case 1:       return $form1;     case 2:     case 3:     case 4:       return $form2;     default:       return $form5;   } } <\/code><\/pre>\n<p>  \u0418 \u0434\u0430\u0436\u0435 \u0431\u043e\u043b\u044c\u0448\u0435, xslt \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0432\u044b\u0437\u0432\u0430\u0442\u044c \u044d\u0442\u0443 \u0444\u0443\u043d\u043a\u0446\u0438\u044e \u043f\u0440\u044f\u043c\u043e \u0438\u0437 \u0448\u0430\u0431\u043b\u043e\u043d\u0430  <\/p>\n<pre><code class=\"xml\">&lt;xsl:value-of select=&quot;php:function('str_plural_form', 1*$cnt_users, '\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c', '\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f', '\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439')&quot;\/&gt; <\/code><\/pre>\n<p>  \u041d\u043e \u044d\u0442\u043e \u043d\u0435 \u0442\u043e\u043b\u044c\u043a\u043e \u043f\u0440\u043e\u0442\u0438\u0432\u043e\u0440\u0435\u0447\u0438\u0442 \u0437\u0430\u0433\u043e\u043b\u043e\u0432\u043a\u0443 \u0440\u0430\u0437\u0434\u0435\u043b\u0430, \u043d\u043e \u0438 \u044f\u0432\u043b\u044f\u0435\u0442\u0441\u044f \u043d\u0435\u043a\u0438\u043c \u0430\u0442\u0430\u0432\u0438\u0437\u043c\u043e\u043c. \u041b\u0443\u0447\u0448\u0435 \u0438\u0437\u0431\u0435\u0433\u0430\u0442\u044c \u0432\u044b\u0437\u043e\u0432\u043e\u0432 php-\u0444\u0443\u043d\u043a\u0446\u0438\u0439 \u0432\u043d\u0443\u0442\u0440\u0438 xslt-\u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432.<br \/>  \u0427\u0442\u043e \u0436\u0435 \u0434\u0435\u043b\u0430\u0442\u044c? \u0415\u0441\u0442\u044c 2 \u0432\u044b\u0445\u043e\u0434\u0430:  <\/p>\n<ol>\n<li>\u043f\u0443\u0441\u0442\u044c \u043a\u043e\u043d\u0442\u0440\u043e\u043b\u0435\u0440 \u0432\u044b\u0437\u044b\u0432\u0430\u0435\u0442 str_plural_form \u0438 \u043e\u0442\u0434\u0430\u0451\u0442 \u043d\u0443\u0436\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435<\/li>\n<li>\u0441\u0434\u0435\u043b\u0430\u0442\u044c \u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0448\u0430\u0431\u043b\u043e\u043d-\u0444\u0443\u043d\u043a\u0446\u0438\u044e, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u043c\u044b \u043f\u043e\u043c\u0435\u0441\u0442\u0438\u043c \u0432 \/themes\/inc\/functions.xsl<\/li>\n<\/ol>\n<p>  <\/p>\n<pre><code class=\"xml\">&lt;xsl:template name=&quot;f_plural_form&quot;&gt;     &lt;xsl:param name=&quot;num&quot;&gt;&lt;\/xsl:param&gt;     &lt;xsl:param name=&quot;format&quot;&gt;### ###&lt;\/xsl:param&gt;     &lt;xsl:param name=&quot;is_show_num&quot;&gt;1&lt;\/xsl:param&gt;     &lt;xsl:param name=&quot;space&quot;\/&gt;          &lt;xsl:param name=&quot;str1&quot;&gt;\u0448\u0442\u0443\u043a\u0430&lt;\/xsl:param&gt;     &lt;xsl:param name=&quot;str2&quot;&gt;\u0448\u0442\u0443\u043a\u0438&lt;\/xsl:param&gt;     &lt;xsl:param name=&quot;str5&quot;&gt;\u0448\u0442\u0443\u043a&lt;\/xsl:param&gt;          &lt;xsl:if test=&quot;$is_show_num=1&quot;&gt;       &lt;xsl:value-of select=&quot;format-number($num, $format)&quot;\/&gt;       &lt;xsl:choose&gt;         &lt;xsl:when test=&quot;$space!=''&quot;&gt;           &lt;xsl:value-of select=&quot;$space&quot; disable-output-escaping=&quot;yes&quot;\/&gt;             &lt;\/xsl:when&gt;         &lt;xsl:otherwise&gt;           &lt;xsl:text&gt; &lt;\/xsl:text&gt;         &lt;\/xsl:otherwise&gt;       &lt;\/xsl:choose&gt;     &lt;\/xsl:if&gt;          &lt;xsl:variable name=&quot;lastN&quot; select=&quot;$num mod 10&quot;\/&gt;     &lt;xsl:variable name=&quot;lastT&quot; select=&quot;$num mod 100&quot;\/&gt;          &lt;xsl:choose&gt;       &lt;xsl:when test=&quot;$lastT&gt;=10 and 20&gt;=$lastT&quot;&gt;         &lt;xsl:value-of select=&quot;$str5&quot; disable-output-escaping=&quot;yes&quot;\/&gt;       &lt;\/xsl:when&gt;       &lt;xsl:when test=&quot;$lastN=1&quot;&gt;         &lt;xsl:value-of select=&quot;$str1&quot; disable-output-escaping=&quot;yes&quot;\/&gt;       &lt;\/xsl:when&gt;             &lt;xsl:when test=&quot;$lastN=2 or $lastN=3 or $lastN=4&quot;&gt;         &lt;xsl:value-of select=&quot;$str2&quot; disable-output-escaping=&quot;yes&quot;\/&gt;       &lt;\/xsl:when&gt;       &lt;xsl:otherwise&gt;         &lt;xsl:value-of select=&quot;$str5&quot; disable-output-escaping=&quot;yes&quot;\/&gt;       &lt;\/xsl:otherwise&gt;           &lt;\/xsl:choose&gt; &lt;\/xsl:template&gt; <\/code><\/pre>\n<p>  \u0412\u044b\u0437\u043e\u0432 \u0444\u0443\u043d\u043a\u0446\u0438\u0438 \u0431\u0443\u0434\u0435\u0442 \u0432\u044b\u0433\u043b\u044f\u0434\u0435\u0442\u044c \u0442\u0430\u043a  <\/p>\n<pre><code class=\"xml\">&lt;xsl:call-template name=&quot;f_plural_form&quot;&gt;   &lt;xsl:with-param name=&quot;is_show_num&quot;&gt;1&lt;\/xsl:with-param&gt;   &lt;xsl:with-param name=&quot;num&quot; select=&quot;$cnt_users&quot;\/&gt;   &lt;xsl:with-param name=&quot;str1&quot;&gt;\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044c&lt;\/xsl:with-param&gt;   &lt;xsl:with-param name=&quot;str2&quot;&gt;\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f&lt;\/xsl:with-param&gt;   &lt;xsl:with-param name=&quot;str5&quot;&gt;\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439&lt;\/xsl:with-param&gt; &lt;\/xsl:call-template&gt; <\/code><\/pre>\n<h4>5. \u0421\u043f\u0440\u0430\u0432\u043e\u0447\u043d\u0438\u043a\u0438<\/h4>\n<p>  \u0412\u0435\u0440\u043d\u0451\u043c\u0441\u044f \u043a \u0432\u044b\u0432\u043e\u0434\u0443 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435. \u041a \u043f\u0440\u0438\u043c\u0435\u0440\u0443 \u043d\u0430 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0435 \u0444\u043e\u0440\u0443\u043c\u0430 \u043d\u0430\u043c \u043d\u0443\u0436\u043d\u043e \u0432\u044b\u0432\u0435\u0441\u0442\u0438   <\/p>\n<ul>\n<li>\u0441\u043f\u0438\u0441\u043e\u043a \u043f\u043e\u0441\u0442\u043e\u0432 \u0441 \u0438\u043c\u0435\u043d\u0430\u043c\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439, <\/li>\n<li>\u0441\u043f\u0438\u0441\u043e\u043a \u0441\u0430\u043c\u044b\u0445 \u0430\u043a\u0442\u0438\u0432\u043d\u044b\u0445 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439,<\/li>\n<li>\u0441\u043f\u0438\u0441\u043e\u043a \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435\u0439 \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0432 \u0434\u0430\u043d\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u043f\u0440\u043e\u0441\u043c\u0430\u0442\u0440\u0438\u0432\u0430\u044e\u0442 \u044d\u0442\u0443 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0443.<\/li>\n<\/ul>\n<p>  \u041c\u043e\u0436\u043d\u043e \u0440\u0435\u0448\u0438\u0442\u044c \u0437\u0430\u0434\u0430\u0447\u0443 \u0432\u043b\u043e\u0431. \u041f\u0440\u0438 \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0438 \u043a\u0430\u0436\u0434\u043e\u0433\u043e \u0438\u0437 \u0441\u043f\u0438\u0441\u043a\u043e\u0432 \u0434\u0435\u043b\u0430\u0442\u044c LEFT JOIN users \u0438 \u043f\u043e\u043b\u0443\u0447\u0430\u0442\u044c \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 \u0434\u043b\u044f \u0432\u044b\u0432\u043e\u0434\u0430 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435. \u041d\u043e \u0435\u0441\u0442\u044c \u0438 \u043e\u0442\u0440\u0438\u0446\u0430\u0442\u0435\u043b\u044c\u043d\u044b\u0435 \u043c\u043e\u043c\u0435\u043d\u0442\u044b \u0442\u0430\u043a\u043e\u0433\u043e \u0440\u0435\u0448\u0435\u043d\u0438\u044f. \u041f\u0435\u0440\u0432\u043e\u0435 \u2014 \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u0430\u044f \u0438\u0437\u0431\u044b\u0442\u043e\u0447\u043d\u043e\u0441\u0442\u044c \u0434\u0430\u043d\u043d\u044b\u0445 (\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0438 \u0438\u0437 \u0441\u043f\u0438\u0441\u043a\u043e\u0432 \u043c\u043e\u0433\u0443\u0442 \u043f\u043e\u0432\u0442\u043e\u0440\u044f\u0442\u044c\u0441\u044f), \u0432\u0442\u043e\u0440\u043e\u0435 \u2014 \u0434\u043e\u043f\u043e\u043b\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u0430\u044f \u043d\u0430\u0433\u0440\u0443\u0437\u043a\u0430 \u043d\u0430 sql-\u0441\u0435\u0440\u0432\u0435\u0440.<\/p>\n<p>  \u0414\u0440\u0443\u0433\u043e\u0439 \u0432\u0430\u0440\u0438\u0430\u043d\u0442 \u0440\u0435\u0448\u0435\u043d\u0438\u044f \u0437\u0430\u0434\u0430\u0447\u0438. \u041f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0432\u0441\u0435 \u0441\u043f\u0438\u0441\u043a\u0438. \u0417\u0430\u0442\u0435\u043c \u0438\u0437 \u044d\u0442\u0438\u0445 \u0441\u043f\u0438\u0441\u043a\u043e\u0432 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u043d\u0430\u0431\u043e\u0440 user_id. \u0418 \u043f\u043e \u044d\u0442\u043e\u043c\u0443 \u043d\u0430\u0431\u043e\u0440\u0443 \u0441\u0434\u0435\u043b\u0430\u0442\u044c \u043e\u0434\u0438\u043d \u0437\u0430\u043f\u0440\u043e\u0441 \u043a \u0442\u0430\u0431\u043b\u0438\u0446\u0435 users. \u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u0441\u043b\u043e\u0436\u0438\u0442\u044c \u0432 xml \u043f\u043e \u0438\u0437\u0432\u0435\u0441\u0442\u043d\u043e\u043c\u0443 \u0430\u0434\u0440\u0435\u0441\u0443, \u043d\u0430\u043f\u0440\u0438\u043c\u0435\u0440 \/ref_users.<br \/>  \u0412 \u0438\u0442\u043e\u0433\u0435 \u0443 \u043d\u0430\u0441 \u0434\u043e\u043b\u0436\u0435\u043d \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c\u0441\u044f xml-\u0434\u043e\u043a\u0443\u043c\u0435\u043d\u0442 \u0441 \u0443\u0437\u043b\u0430\u043c\u0438 posts, active_users, online_users, ref_users.<\/p>\n<p>  \u0414\u043b\u044f \u0432\u044b\u0432\u043e\u0434\u0430 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435 \u0441\u0434\u0435\u043b\u0430\u0435\u043c \u0442\u0430\u043a\u043e\u0439 \u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u044b\u0439 \u0448\u0430\u0431\u043b\u043e\u043d  <\/p>\n<pre><code class=\"xml\">&lt;xsl:template name=&quot;inc_show_user_by_id&quot;&gt;     &lt;xsl:param name=&quot;user_id&quot;\/&gt;          &lt;!-- \u043f\u043e\u0438\u0441\u043a \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0432 \u0441\u043f\u0440\u0430\u0432\u043e\u0447\u043d\u0438\u043a\u0435 \u043f\u043e \u0435\u0433\u043e id --&gt;     &lt;xsl:variable name=&quot;cur_user&quot; select=&quot;\/*\/ref_users\/item[user_id=$user_id]&quot;\/&gt;     &lt;xsl:call-template name=&quot;inc_show_user&quot;&gt;         &lt;xsl:with-param name=&quot;user&quot; select=&quot;$cur_user&quot;\/&gt;     &lt;\/xsl:call-template&gt; &lt;\/xsl:template&gt; <\/code><\/pre>\n<p> \u0438 \u0441\u043e\u0445\u0440\u0430\u043d\u0438\u043c \u0435\u0433\u043e \u0432 \/themes\/models\/user.xsl. \u042d\u0442\u043e \u0448\u0430\u0431\u043b\u043e\u043d \u0434\u043b\u044f \u0432\u044b\u0432\u043e\u0434\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u043f\u043e \u0435\u0433\u043e id.<\/p>\n<p>  \u0412\u044b\u0432\u0435\u0441\u0442\u0438 \u0441\u043f\u0438\u0441\u043e\u043a \u043f\u043e\u0441\u0442\u043e\u0432 \u0441 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0435\u0439 \u043e \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u0435 \u043c\u043e\u0436\u043d\u043e \u0442\u0430\u043a  <\/p>\n<pre><code class=\"xml\">&lt;xsl:for-each select=&quot;posts\/item&quot;&gt;     &lt;xsl:call-template name=&quot;inc_show_user_by_id&quot;&gt;         &lt;!-- \u043f\u0435\u0440\u0435\u0434\u0430\u0451\u043c \u0432 \u0448\u0430\u0431\u043b\u043e\u043d user_id \u0430\u0432\u0442\u043e\u0440\u0430 \u043f\u043e\u0441\u0442\u0430 --&gt;         &lt;xsl:with-param name=&quot;user_id&quot; select=&quot;user_id&quot;\/&gt;     &lt;\/xsl:call-template&gt;          &lt;!-- \u0434\u0430\u043b\u0435\u0435 \u0432\u044b\u0432\u043e\u0434 \u0441\u0430\u043c\u043e\u0433\u043e \u043f\u043e\u0441\u0442\u0430 --&gt;     &lt;!-- ... --&gt; &lt;\/xsl:for-each&gt; <\/code><\/pre>\n<h4>\u0417\u0430\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435<\/h4>\n<p>  \u0421\u0442\u0430\u0442\u044c\u044f \u043f\u043e\u043b\u0443\u0447\u0438\u043b\u0430\u0441\u044c \u043e\u0431\u044a\u0451\u043c\u043d\u043e\u0439, \u043f\u043e\u044d\u0442\u043e\u043c\u0443 \u043d\u0435 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u043d\u044b\u043c\u0438 \u043e\u0441\u0442\u0430\u043b\u0438\u0441\u044c \u0432\u043e\u043f\u0440\u043e\u0441\u044b \u043e\u0440\u0433\u0430\u043d\u0438\u0437\u0430\u0446\u0438\u0438 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432 \u0434\u043b\u044f ajax, \u00ab\u0430\u0431\u0441\u0442\u0440\u0430\u043a\u0442\u043d\u044b\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u044b\u00bb, \u043f\u043e\u0434\u0434\u0435\u0440\u0436\u043a\u0430 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u044f\u0437\u044b\u043a\u043e\u0432. \u0410 \u0442\u0430\u043a\u0436\u0435 \u0432\u043e\u043f\u0440\u043e\u0441\u044b \u0441\u043a\u043e\u0440\u043e\u0441\u0442\u0438 \u0438 \u043a\u0435\u0448\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044f.    \t   \t<\/p>\n<div class=\"clear\"><\/div>\n<\/p><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/post\/151241\/\"> http:\/\/habrahabr.ru\/post\/151241\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"content html_format\">   \t\u0412 \u0441\u0442\u0430\u0442\u044c\u0435 \u0432\u044b \u043d\u0435 \u043d\u0430\u0439\u0434\u0451\u0442\u0435 \u0441\u0440\u0430\u0432\u043d\u0438\u0442\u0435\u043b\u044c\u043d\u044b\u0445 \u0442\u0435\u0441\u0442\u043e\u0432 \u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0442\u043e\u0440\u043e\u0432. \u0417\u0430\u0442\u043e \u043d\u0430\u0439\u0434\u0451\u0442\u0435 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e\u0431 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0438 xslt \u0432 \u043a\u0430\u0447\u0435\u0441\u0442\u0432\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u0438\u0437\u0430\u0442\u043e\u0440\u0430 \u043d\u0430 \u0440\u0435\u0430\u043b\u044c\u043d\u044b\u0445 \u043f\u0440\u043e\u0435\u043a\u0442\u0430\u0445. \u0420\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d\u044b \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u043e\u0441\u0442\u0438 \u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u044b\u0445 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u043e\u0432-\u0444\u0443\u043d\u043a\u0446\u0438\u0439, \u0441\u043f\u0440\u0430\u0432\u043e\u0447\u043d\u0438\u043a\u043e\u0432.<\/p>\n<h4>1. \u0421\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0430 \u043f\u0440\u043e\u0435\u043a\u0442\u0430<\/h4>\n<p>  \u041e\u0431\u044b\u0447\u043d\u043e \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430 \u0441\u0430\u0439\u0442\u0430 \u0441\u043e\u0441\u0442\u043e\u0438\u0442 \u0438\u0437 \u043d\u0435\u0441\u043a\u043e\u043b\u044c\u043a\u0438\u0445 \u043e\u0431\u0449\u0438\u0445 \u0431\u043b\u043e\u043a\u043e\u0432 (\u043c\u0435\u043d\u044e, \u0444\u0443\u0442\u0435\u0440, &#8230;) \u0438 \u043a\u043e\u043d\u0442\u0435\u043d\u0442\u043d\u043e\u0439 \u0447\u0430\u0441\u0442\u0438, \u043a\u043e\u0442\u043e\u0440\u0443\u044e \u0434\u043b\u044f \u043e\u0431\u0449\u043d\u043e\u0441\u0442\u0438 \u0431\u0443\u0434\u0435\u043c \u043d\u0430\u0437\u044b\u0432\u0430\u0442\u044c \u043e\u0441\u043d\u043e\u0432\u043d\u044b\u043c \u0431\u043b\u043e\u043a\u043e\u043c. \u0412\u0441\u0435 \u044d\u0442\u0438 \u0431\u043b\u043e\u043a\u0438 \u0440\u0430\u0437\u043c\u0435\u0449\u0430\u044e\u0442\u0441\u044f \u0432\u043d\u0443\u0442\u0440\u0438 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0438\u043d\u0434\u0435\u043a\u0441\u043d\u043e\u0433\u043e \u0448\u0430\u0431\u043b\u043e\u043d\u0430, \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0437\u043d\u0430\u0435\u0442 \u0432 \u043a\u0430\u043a\u043e\u043c \u043c\u0435\u0441\u0442\u0435 \u043a\u0430\u043a\u043e\u0439 \u0431\u043b\u043e\u043a \u043e\u0442\u043e\u0431\u0440\u0430\u0437\u0438\u0442\u044c: \u043c\u0435\u043d\u044e \u0434\u043e\u043b\u0436\u043d\u043e \u0431\u044b\u0442\u044c \u0432\u0432\u0435\u0440\u0445\u0443, \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0439 \u0431\u043b\u043e\u043a \u0432 \u0446\u0435\u043d\u0442\u0440\u0435, \u0430 \u0444\u0443\u0442\u0435\u0440 \u0432\u043d\u0438\u0437\u0443.<\/p>\n<p>  \u041f\u043e\u043b\u0443\u0447\u0430\u0435\u043c \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0443\u044e \u0441\u0442\u0440\u0443\u043a\u0442\u0443\u0440\u0443  <\/p>\n<pre><code class=\"bash\">\/themes - \u0437\u0434\u0435\u0441\u044c \u0440\u0430\u043f\u043e\u043b\u0430\u0433\u0430\u044e\u0442\u0441\u044f \u0432\u0441\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u044b \/themes\/index\/main.xsl - \u0438\u043d\u0434\u0435\u043a\u0441\u043d\u044b\u0439 \u0448\u0430\u0431\u043b\u043e\u043d \/themes\/models\/user.xsl - \u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u0442\u043d\u043e\u0441\u044f\u0442\u0441\u044f \u043a \u043c\u043e\u0434\u0435\u043b\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \/themes\/inc\/functions.xsl - \u0438\u043c\u0435\u043d\u043e\u0432\u0430\u043d\u043d\u044b\u0435 \u0448\u0430\u0431\u043b\u043e\u043d\u044b-\u0444\u0443\u043d\u043a\u0446\u0438\u0438 \/themes\/blocks\/footer.xsl - \u0448\u0430\u0431\u043b\u043e\u043d \u0444\u0443\u0442\u0435\u0440\u0430 \/themes\/blocks\/menu.xsl - \u0448\u0430\u0431\u043b\u043e\u043d \u043c\u0435\u043d\u044e \/themes\/cabinet\/main.xsl - \u0448\u0430\u0431\u043b\u043e\u043d \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0433\u043e \u0431\u043b\u043e\u043a\u0430 \u0433\u043b\u0430\u0432\u043d\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043a\u0430\u0431\u0438\u043d\u0435\u0442\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f <\/code><\/pre>\n<p>  \u041a\u043e\u043d\u0442\u0440\u043e\u043b\u043b\u0435\u0440 \u0433\u043b\u0430\u0432\u043d\u043e\u0439 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u043a\u0430\u0431\u0438\u043d\u0435\u0442\u0430 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u043c \u043e\u0431\u0440\u0430\u0437\u043e\u043c:  <\/p>\n<ol>\n<li>\u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442 \u0434\u0430\u043d\u043d\u044b\u0435 \u0434\u043b\u044f \u043e\u0441\u043d\u043e\u0432\u043d\u043e\u0433\u043e \u0431\u043b\u043e\u043a\u0430, \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u0442 \u0438\u0445 \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \/themes\/cabinet\/main.xsl \u0438 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 (\u0433\u043e\u0442\u043e\u0432\u044b\u0439 html) \u043f\u043e\u043c\u0435\u0449\u0430\u0435\u0442 \u0432 \u0438\u0442\u043e\u0433\u043e\u0432\u044b\u0439 xml<\/li>\n<li>\u0430\u043d\u0430\u043b\u043e\u0433\u0438\u0447\u043d\u043e \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u0442 \u0434\u0430\u043d\u043d\u044b\u0435 \u0434\u043b\u044f \u0434\u0440\u0443\u0433\u0438\u0445 \u0431\u043b\u043e\u043a\u043e\u0432 (\u043c\u0435\u043d\u044e, \u0444\u0443\u0442\u0435\u0440) \u0438 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043f\u043e\u043c\u0435\u0449\u0430\u0435\u0442 \u0432 xml<\/li>\n<li>\u0438\u0442\u043e\u0433\u043e\u0432\u044b\u0439 xml, \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u043c \u043d\u0430\u0445\u043e\u0434\u044f\u0442\u0441\u044f \u0434\u0430\u043d\u043d\u044b\u0435 \u0432\u0441\u0435\u0445 \u0431\u043b\u043e\u043a\u043e\u0432, \u043e\u0431\u0440\u0430\u0431\u0430\u0442\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u0438\u043d\u0434\u0435\u043a\u0441\u043d\u043e\u0433\u043e \u0448\u0430\u0431\u043b\u043e\u043d\u0430 \/themes\/index\/main.xsl \u0438 \u0440\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442 \u043e\u0442\u0434\u0430\u0451\u0442 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u0435\u043b\u044e.<\/li>\n<\/ol>\n<p>  <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-151241","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/151241","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=151241"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/151241\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=151241"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=151241"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=151241"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}