{"id":233546,"date":"2017-01-05T22:34:56","date_gmt":"2017-01-05T22:34:56","guid":{"rendered":"https:\/\/ru.wordpress.org\/support\/topic\/%d0%bf%d0%be%d0%b4%d0%ba%d0%bb%d1%8e%d1%87%d0%b5%d0%bd%d0%b8%d0%b5-style-css-%d0%b2-function-php\/"},"modified":"2017-01-06T10:48:47","modified_gmt":"2017-01-06T10:48:47","slug":"%d0%bf%d0%be%d0%b4%d0%ba%d0%bb%d1%8e%d1%87%d0%b5%d0%bd%d0%b8%d0%b5-style-css-%d0%b2-function-php","status":"publish","type":"topic","link":"https:\/\/ru.wordpress.org\/support\/topic\/%d0%bf%d0%be%d0%b4%d0%ba%d0%bb%d1%8e%d1%87%d0%b5%d0%bd%d0%b8%d0%b5-style-css-%d0%b2-function-php\/","title":{"rendered":"\u041f\u043e\u0434\u043a\u043b\u044e\u0447\u0435\u043d\u0438\u0435 style.css \u0432 function.php"},"content":{"rendered":"<p>\u0417\u0434\u0440\u0430\u0432\u0441\u0442\u0432\u0443\u0439\u0442\u0435, \u043d\u0435 \u043c\u043e\u0433\u0443 \u043f\u043e\u0434\u043a\u043b\u044e\u0447\u0438\u0442\u044c css \u0447\u0435\u0440\u0435\u0437 function.php. \u0414\u0435\u043b\u0430\u044e \u043a\u0430\u043a \u0432 \u0440\u0443\u043a\u043e\u0432\u043e\u0434\u0441\u0442\u0432\u0430\u0445, \u0445\u0440\u043e\u043d\u0438\u0447\u0435\u0441\u043a\u0438 \u043d\u0438\u0447\u0435\u0433\u043e \u043d\u0435 \u0432\u044b\u0445\u043e\u0434\u0438\u0442, \u0430 \u0432\u043e\u0442 \u0442\u0430\u043a  <code>&lt;link rel=&quot;stylesheet&quot; href=&quot;&lt;?php bloginfo(&#039;stylesheet_url&#039;);?&gt;<\/code> \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0441\u044f, \u043d\u043e \u0433\u043e\u0432\u043e\u0440\u044f\u0442, \u043d\u0443\u0436\u043d\u043e \u0447\u0435\u0440\u0435\u0437 function.<\/p>\n<p>function.php \u0443 \u043c\u0435\u043d\u044f \u0442\u0430\u043a\u043e\u0435:<\/p>\n<pre><code>\n&lt;?php\nfunction load_style_script(){\n wp_enqueue_style(&#039;style&#039;, get_template_directory_uri() . &#039;\/style.css&#039;);\n}\nadd_action(&#039;wp_enqueue_scripts&#039;, &#039;load_style_script&#039;);\n?&gt;\n<\/code><\/pre>\n<p>style.css \u0442\u0430\u043a\u043e\u0439:<\/p>\n<pre><code>\n\ufeff\/*Theme Name: gymbalance\nTheme URI: http:\/\/gymbalance.ru\nAuthor: Andrei Filimonov\nAuthor URI: http:\/\/gymbalance.ru\nDescription: \u041e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u0442\u0435\u043c\u044b\nVersion: 1.0*\/\n\n* {\nmargin:0; \/*\u0420\u045b\u0420\u00b1\u0420\u0405\u0421\u0453\u0420\u00bb\u0421\u040f\u0420\u00b5\u0420\u0458 \u0420\u0406\u0421\u0403\u0420\u00b5 \u0420\u0455\u0421\u201a\u0421\u0403\u0421\u201a\u0421\u0453\u0420\u0457\u0421\u2039, \u0420\u0406 \u0420\u0405\u0421\u0453\u0420\u00b6\u0420\u0405\u0421\u2039\u0421\u2026 \u0420\u0458\u0420\u00b5\u0421\u0403\u0421\u201a\u0420\u00b0\u0421\u2026 \u0420\u0491\u0420\u0455\u0420\u00b1\u0420\u00b0\u0420\u0406\u0420\u0451\u0420\u0458 \u0420\u0451\u0421\u2026*\/\npadding:0;\n}\nbody {\nfont-family: Arial, Helvetica, sans-serif; \/*\u0420\u00b7\u0420\u00b0\u0420\u0491\u0420\u00b0\u0420\u00b5\u0420\u0458 \u0420\u0455\u0421\u0403\u0420\u0405\u0420\u0455\u0420\u0406\u0420\u0405\u0420\u0455\u0420\u2116 \u0421\u20ac\u0421\u0402\u0420\u0451\u0421\u201e\u0421\u201a \u0421\u201a\u0420\u00b5\u0420\u0454\u0421\u0403\u0421\u201a\u0420\u00b0*\/\ndisplay:block; \/*\u0420\u2014\u0420\u00b0\u0421\u0403\u0421\u201a\u0420\u00b0\u0420\u0406\u0420\u00bb\u0421\u040f\u0420\u00b5\u0420\u0458 \u0420\u0406\u0421\u0403\u0420\u00b5 \u0421\u040c\u0420\u00bb\u0420\u00b5\u0420\u0458\u0420\u00b5\u0420\u0405\u0421\u201a\u0421\u2039 \u0420\u0406\u0420\u00b5\u0421\u0403\u0421\u201a\u0420\u0451 \u0421\u0403\u0420\u00b5\u0420\u00b1\u0421\u040f \u0420\u0454\u0420\u00b0\u0420\u0454 \u0420\u00b1\u0420\u00bb\u0420\u0455\u0421\u2021\u0420\u0405\u0421\u2039\u0420\u00b5*\/\nbackground: #ffffe0;\n}\n.header {\n\twidth: 100%;\n\tmin-width:1000px;\n\theight: 120px;\n\tpadding-top:10px;\n\tmargin-bottom: 5px;\n\ttext-align: center;\n\tbackground: #ffffe0;\n}\n.header-present {\n\theight: 90px;\n}\n.logo {\n\tmargin-left: 20px;\n\twidth: 430px;\n\tfloat: right;\n}\n.site-title {\nfont-family: Arial, Helvetica, sans-serif;\nfloat:right;\ntext-align: justify;\nmargin-right: 20px;\n}\n.site-title h1 {\n\tfont-size: 40px;\n}\n.site-title p {\n\tfont-size: 20px;\n}\n.menu {\nmargin:5px 20px 0 20px;\n}\n.menu li {\n\tlist-style-type: none;\n\tfont-size: 20px;\n        display: inline;\n\tmargin-left: 25px;\n}\n.menu li a {\ncolor:#165F12; text-decoration:none;\t\n}\n.menu li a:hover{\ncolor:#fff; text-decoration:none;\n}\n<\/code><\/pre>\n","protected":false},"template":"","class_list":["post-233546","topic","type-topic","status-publish","hentry","topic-tag-function-php"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/ru.wordpress.org\/support\/wp-json\/wp\/v2\/topic\/233546","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":1,"href":"https:\/\/ru.wordpress.org\/support\/wp-json\/wp\/v2\/topic\/233546\/revisions"}],"predecessor-version":[{"id":233551,"href":"https:\/\/ru.wordpress.org\/support\/wp-json\/wp\/v2\/topic\/233546\/revisions\/233551"}],"wp:attachment":[{"href":"https:\/\/ru.wordpress.org\/support\/wp-json\/wp\/v2\/media?parent=233546"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}