{"id":330996,"date":"2019-07-30T20:07:52","date_gmt":"2019-07-30T17:07:52","guid":{"rendered":"https:\/\/ru.wordpress.org\/support\/topic\/%d0%bd%d0%b5-%d1%80%d0%b0%d0%b1%d0%be%d1%82%d0%b0%d0%b5%d1%82-%d0%bf%d0%b0%d0%b3%d0%b8%d0%bd%d0%b0%d1%86%d0%b8%d1%8f-%d0%b4%d0%bb%d1%8f-%d0%bf%d1%80%d0%be%d0%b8%d0%b7%d0%b2%d0%be%d0%bb%d1%8c%d0%bd\/"},"modified":"2019-07-30T20:07:52","modified_gmt":"2019-07-30T17:07:52","slug":"%d0%bd%d0%b5-%d1%80%d0%b0%d0%b1%d0%be%d1%82%d0%b0%d0%b5%d1%82-%d0%bf%d0%b0%d0%b3%d0%b8%d0%bd%d0%b0%d1%86%d0%b8%d1%8f-%d0%b4%d0%bb%d1%8f-%d0%bf%d1%80%d0%be%d0%b8%d0%b7%d0%b2%d0%be%d0%bb%d1%8c%d0%bd","status":"publish","type":"topic","link":"https:\/\/ru.wordpress.org\/support\/topic\/%d0%bd%d0%b5-%d1%80%d0%b0%d0%b1%d0%be%d1%82%d0%b0%d0%b5%d1%82-%d0%bf%d0%b0%d0%b3%d0%b8%d0%bd%d0%b0%d1%86%d0%b8%d1%8f-%d0%b4%d0%bb%d1%8f-%d0%bf%d1%80%d0%be%d0%b8%d0%b7%d0%b2%d0%be%d0%bb%d1%8c%d0%bd\/","title":{"rendered":"\u041d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u043f\u0430\u0433\u0438\u043d\u0430\u0446\u0438\u044f \u0434\u043b\u044f \u043f\u0440\u043e\u0438\u0437\u0432\u043e\u043b\u044c\u043d\u043e\u0433\u043e \u0442\u0438\u043f\u0430 \u0437\u0430\u043f\u0438\u0441\u0435\u0439."},"content":{"rendered":"<p>\u0414\u043e\u0431\u0440\u044b\u0439 \u0432\u0435\u0447\u0435\u0440.<br \/>\n\u0412 \u043d\u0430\u0441\u0442\u0440\u043e\u0439\u043a\u0430\u0445 \u0432\u044b\u0441\u0442\u0430\u0432\u0438\u043b, \u0447\u0442\u043e\u0431\u044b \u0432\u044b\u0432\u043e\u0434\u0438\u043b\u0438\u0441\u044c \u0442\u043e\u043b\u044c\u043a\u043e 2 \u0437\u0430\u043f\u0438\u0441\u0438.<br \/>\n\u0421\u043e\u0437\u0434\u0430\u043b \u0444\u0430\u0439\u043b archive-portfolio.php \u0434\u043b\u044f \u0442\u0438\u043f\u0430 \u0437\u0430\u043f\u0438\u0441\u0435\u0439 \u043f\u043e\u0440\u0442\u0444\u043e\u043b\u0438\u043e. <\/p>\n<p>\u041c\u043d\u0435 \u043d\u0443\u0436\u043d\u043e, \u0447\u0442\u043e\u0431\u044b \u0432\u044b\u0432\u043e\u0434\u0438\u043b\u0438\u0441\u044c 10 \u0437\u0430\u043f\u0438\u0441\u0435\u0439, \u043d\u043e \u0432\u044b\u0432\u043e\u0434\u044f\u0442\u0441\u044f 2 \u0432 \u043e\u0431\u044b\u0447\u043d\u043e\u043c \u0446\u0438\u043a\u043b\u0435 wordpress.<br \/>\n\u042f \u043f\u043e\u043f\u044b\u0442\u0430\u043b\u0441\u044f \u0447\u0435\u0440\u0435\u0437 wp_query \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u044c, \u0447\u0435\u0440\u0435\u0437 \u043e\u043f\u0446\u0438\u044e &#8216;posts_per_page&#8217;, \u0432\u044b\u0432\u043e\u0434\u044f\u0442\u0441\u044f \u043a\u0430\u043a \u043c\u043d\u0435 \u043d\u0443\u0436\u043d\u043e, \u043d\u043e \u043f\u0440\u0438 \u044d\u0442\u043e\u043c \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u0438 \u043f\u0430\u0433\u0438\u043d\u0430\u0446\u0438\u044f. <\/p>\n<pre><code>&lt;?php\nget_header();\n?&gt;\n    &lt;?php get_template_part(&#039;template-parts\/services&#039;); ?&gt;\n\n    &lt;div class=&quot;main-content&quot;&gt;\n        &lt;div class=&quot;container&quot;&gt;\n            &lt;header class=&quot;page-header&quot;&gt;\n                &lt;h1 class=&quot;header-title&quot;&gt;&lt;?php echo __(&#039;Portfolio&#039;, &#039;bs_sonaris&#039;); ?&gt;&lt;\/h1&gt;\n            &lt;\/header&gt;&lt;!-- .page-header --&gt;\n\n            &lt;div class=&quot;section section-portfolio&quot;&gt;\n                &lt;div class=&quot;portfolio&quot;&gt;\n                    &lt;?php\n                        $portfolio = new WP_Query([\n                            &#039;post_type&#039; =&gt; &#039;portfolio&#039;,\n                            &#039;posts_per_page&#039; =&gt; 6\n                        ]);\n                    ?&gt;\n\n                    &lt;?php $GLOBALS[&quot;wp_query&quot;] = $portfolio; ?&gt;\n\n                    &lt;?php if($portfolio-&gt;have_posts()): ?&gt;\n                        &lt;?php while($portfolio-&gt;have_posts()): ?&gt;\n                            &lt;?php $portfolio-&gt;the_post(); ?&gt;\n                            &lt;?php\n                                $thumb_url = kama_thumb_src(&#039;w=300 &amp;h=300&#039;);\n                            ?&gt;\n                            &lt;a class=&quot;portfolio-item waves-effect&quot; href=&quot;&lt;?php the_permalink(); ?&gt;&quot;&gt;\n                                &lt;img class=&quot;portfolio-item-img&quot; src=&quot;&lt;?php echo $thumb_url; ?&gt;&quot; alt=&quot;&quot;\/&gt;\n                                &lt;span class=&quot;btn btn-white btn-rounded&quot;&gt;&lt;?php echo __(&#039;More&#039;, &#039;bs_sonaris&#039;) ?&gt;&lt;\/span&gt;\n                            &lt;\/a&gt;\n                        &lt;?php endwhile; ?&gt;\n                        &lt;div class=&quot;portfolio-pagination&quot;&gt;\n                            &lt;?php the_posts_pagination([\n                                &#039;show_all&#039;     =&gt; true, \/\/ \u043f\u043e\u043a\u0430\u0437\u0430\u043d\u044b \u0432\u0441\u0435 \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u044b \u0443\u0447\u0430\u0441\u0442\u0432\u0443\u044e\u0449\u0438\u0435 \u0432 \u043f\u0430\u0433\u0438\u043d\u0430\u0446\u0438\u0438\n                                &#039;end_size&#039;     =&gt; 1,     \/\/ \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0441\u0442\u0440\u0430\u043d\u0438\u0446 \u043d\u0430 \u043a\u043e\u043d\u0446\u0430\u0445\n                                &#039;mid_size&#039;     =&gt; 1,     \/\/ \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e \u0441\u0442\u0440\u0430\u043d\u0438\u0446 \u0432\u043e\u043a\u0440\u0443\u0433 \u0442\u0435\u043a\u0443\u0449\u0435\u0439\n                                &#039;prev_next&#039;    =&gt; false,  \/\/ \u0432\u044b\u0432\u043e\u0434\u0438\u0442\u044c \u043b\u0438 \u0431\u043e\u043a\u043e\u0432\u044b\u0435 \u0441\u0441\u044b\u043b\u043a\u0438 &quot;\u043f\u0440\u0435\u0434\u044b\u0434\u0443\u0449\u0430\u044f\/\u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430&quot;.\n                                &#039;prev_text&#039;    =&gt; __(&#039;\u00ab Previous&#039;),\n                                &#039;next_text&#039;    =&gt; __(&#039;Next \u00bb&#039;),\n                                &#039;add_args&#039;     =&gt; false, \/\/ \u041c\u0430\u0441\u0441\u0438\u0432 \u0430\u0440\u0433\u0443\u043c\u0435\u043d\u0442\u043e\u0432 (\u043f\u0435\u0440\u0435\u043c\u0435\u043d\u043d\u044b\u0445 \u0437\u0430\u043f\u0440\u043e\u0441\u0430), \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043d\u0443\u0436\u043d\u043e \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c \u043a \u0441\u0441\u044b\u043b\u043a\u0430\u043c.\n                                &#039;add_fragment&#039; =&gt; &#039;&#039;,     \/\/ \u0422\u0435\u043a\u0441\u0442 \u043a\u043e\u0442\u043e\u0440\u044b\u0439 \u0434\u043e\u0431\u0430\u0432\u0438\u0442\u044c\u0441\u044f \u043a\u043e \u0432\u0441\u0435\u043c \u0441\u0441\u044b\u043b\u043a\u0430\u043c.\n                                &#039;screen_reader_text&#039; =&gt; __( &#039;&#039; ),\n                            ]); ?&gt;\n                        &lt;\/div&gt;\n                &lt;?php endif; ?&gt;\n\t\t\t\t&lt;?php wp_reset_postdata(); ?&gt;\n        &lt;\/div&gt;\n    &lt;\/div&gt;\n\n&lt;?php\nget_footer();\n\n<\/code><\/pre>\n<p>\u0414\u0430\u0436\u0435 \u043d\u0435 \u0437\u043d\u0430\u044e, \u0447\u0442\u043e \u0434\u0435\u043b\u0430\u0442\u044c.<\/p>\n<p>\u0417\u0430\u0440\u0430\u043d\u0435\u0435 \u0431\u043b\u0430\u0433\u043e\u0434\u0430\u0440\u0435\u043d \u0437\u0430 \u043f\u043e\u0434\u0441\u043a\u0430\u0437\u043a\u0443. <\/p>\n","protected":false},"template":"","class_list":["post-330996","topic","type-topic","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/ru.wordpress.org\/support\/wp-json\/wp\/v2\/topic\/330996","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/ru.wordpress.org\/support\/wp-json\/wp\/v2\/topic"}],"about":[{"href":"https:\/\/ru.wordpress.org\/support\/wp-json\/wp\/v2\/types\/topic"}],"version-history":[{"count":0,"href":"https:\/\/ru.wordpress.org\/support\/wp-json\/wp\/v2\/topic\/330996\/revisions"}],"wp:attachment":[{"href":"https:\/\/ru.wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=330996"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}