{"id":228391,"date":"2022-10-13T16:20:00","date_gmt":"2022-10-13T13:20:00","guid":{"rendered":"https:\/\/wordpress.mediadoma.com\/?p=228391"},"modified":"2022-11-09T02:12:45","modified_gmt":"2022-11-08T23:12:45","slug":"registr-klavish-zmini-masivu","status":"publish","type":"post","link":"https:\/\/wordpress.mediadoma.com\/uk\/registr-klavish-zmini-masivu\/","title":{"rendered":"\u0420\u0435\u0433\u0456\u0441\u0442\u0440 \u043a\u043b\u0430\u0432\u0456\u0448 \u0437\u043c\u0456\u043d\u0438 \u043c\u0430\u0441\u0438\u0432\u0443"},"content":{"rendered":"<p>\u0411\u0430\u0437\u043e\u0432\u0438\u0439 \u043f\u0440\u0438\u043a\u043b\u0430\u0434\u0411\u0430\u0437\u043e\u0432\u0438\u0439 \u043f\u0440\u0438\u043a\u043b\u0430\u0434<br \/>\n\u042f\u043a\u0449\u043e \u043c\u0438\u2026<\/p>\n<p><a href=\"https:\/\/hashnode.com\/@wholesomecode\" target=\"_blank\" rel=\"noopener nofollow\" class=\"external\"><\/a><\/p>\n<p>Array Change Key Case (<code>array_change_key_case<\/code>) \u2014 \u0446\u0435 \u043f\u0440\u043e\u0441\u0442\u0430 \u0444\u0443\u043d\u043a\u0446\u0456\u044f, \u0429\u041e \u0434\u043e\u0437\u0432\u043e\u043b\u044f\u0454 \u0432\u0430\u043c \u0440\u043e\u0431\u0438\u0442\u0438 \u0432\u0441\u0456 \u043a\u043b\u044e\u0447\u0456 \u0432\u0430\u0448\u043e\u0433\u043e \u043c\u0430\u0441\u0438\u0432\u0443 \u0432\u0435\u043b\u0438\u043a\u0438\u043c\u0438 \u0430\u0431\u043e \u043c\u0430\u043b\u0438\u043c\u0438 \u043b\u0456\u0442\u0435\u0440\u0430\u043c\u0438.<\/p>\n<h2>\u0411\u0430\u0437\u043e\u0432\u0438\u0439 \u043f\u0440\u0438\u043a\u043b\u0430\u0434<\/h2>\n<p>\u042f\u043a\u0449\u043e \u043c\u0438 \u0432\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043c\u043e \u043c\u0430\u0441\u0438\u0432 \u0456\u0437 \u043a\u043b\u0430\u0432\u0456\u0448\u0430\u043c\u0438 \u0432\u0435\u0440\u0445\u043d\u044c\u043e\u0433\u043e \u0440\u0435\u0433\u0456\u0441\u0442\u0440\u0443 (\u0440\u044f\u0434\u043e\u043a 1), \u043c\u0438 \u043c\u043e\u0436\u0435\u043c\u043e \u0432\u0438\u043a\u043e\u0440\u0438\u0441\u0442\u0430\u0442\u0438 <code>array_change_key_case<\/code>\u0444\u0443\u043d\u043a\u0446\u0456\u044e, \u0449\u043e\u0431 \u0437\u0440\u043e\u0431\u0438\u0442\u0438 \u0432\u0441\u0456 \u0446\u0456 \u043a\u043b\u044e\u0447\u0456 \u043d\u0438\u0436\u043d\u0456\u043c \u0440\u0435\u0433\u0456\u0441\u0442\u0440\u043e\u043c (\u0440\u044f\u0434\u043e\u043a 5).<\/p>\n<p>\u0426\u0435 \u043f\u043e\u0432\u0435\u0440\u0442\u0430\u0454 \u043d\u0430\u043c \u0442\u043e\u0439 \u0441\u0430\u043c\u0438\u0439 \u043c\u0430\u0441\u0438\u0432, \u0430\u043b\u0435 \u0432\u0441\u0456 \u043a\u043b\u044e\u0447\u0456 \u0432 \u043d\u0438\u0436\u043d\u044c\u043e\u043c\u0443 \u0440\u0435\u0433\u0456\u0441\u0442\u0440\u0456.<\/p>\n<pre><code>$array = [\n    'P' =&gt; 42,\n    'POST_STATUS' =&gt; 'publish',\n];\n$lower_case_array = array_change_key_case( $array, CASE_LOWER );\nprint_r( $lower_case_array ); \n<\/code><\/pre>\n<h2>\u041a\u043e\u043c\u043f\u043e\u0437\u0438\u0446\u0456\u044f<\/h2>\n<pre><code>array_change_key_case( $array, $case );\n<\/code><\/pre>\n<p>\u0424\u0443\u043d\u043a\u0446\u0456\u044f \u043f\u0440\u0438\u0439\u043c\u0430\u0454 \u0434\u0432\u0430 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u0438. \u0412\u0438 <code>$array<\/code>\u0431\u0430\u0436\u0430\u0454\u0442\u0435 \u0437\u043c\u0456\u043d\u0438\u0442\u0438, \u0456 <code>$case<\/code>(\u043d\u0435\u043e\u0431\u043e\u0432&#8217;\u044f\u0437\u043a\u043e\u0432\u043e, <code>CASE_LOWER<\/code>\u0437\u0430 \u0437\u0430\u043c\u043e\u0432\u0447\u0443\u0432\u0430\u043d\u043d\u044f\u043c), \u043d\u0430 \u044f\u043a\u0438\u0439 \u0432\u0438 \u0445\u043e\u0447\u0435\u0442\u0435 \u043f\u0435\u0440\u0435\u0442\u0432\u043e\u0440\u0438\u0442\u0438 \u043a\u043b\u044e\u0447\u0456. \u0426\u0435 \u0442\u0430\u043a\u0456:<\/p>\n<ol>\n<li>\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 <code>$array<\/code>\u043f\u0440\u0438\u0439\u043c\u0430\u0454 \u043c\u0430\u0441\u0438\u0432 \u0456 \u0454 \u043f\u043e\u0447\u0430\u0442\u043a\u043e\u0432\u0438\u043c \u043c\u0430\u0441\u0438\u0432\u043e\u043c, \u044f\u043a\u0438\u0439 \u043c\u0438 \u0445\u043e\u0447\u0435\u043c\u043e \u043f\u0435\u0440\u0435\u0442\u0432\u043e\u0440\u0438\u0442\u0438.<\/li>\n<li>\u041f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 <code>$case<\/code>\u043f\u0440\u0438\u0439\u043c\u0430\u0454 \u0446\u0456\u043b\u0435 \u0447\u0438\u0441\u043b\u043e, \u044f\u043a\u0435 \u0432\u0432\u043e\u0434\u0438\u0442\u044c\u0441\u044f \u0437\u0430 \u0434\u043e\u043f\u043e\u043c\u043e\u0433\u043e\u044e \u043e\u0434\u043d\u0456\u0454\u0457 \u0437 \u0434\u0432\u043e\u0445 \u043f\u043e\u043f\u0435\u0440\u0435\u0434\u043d\u044c\u043e \u0432\u0438\u0437\u043d\u0430\u0447\u0435\u043d\u0438\u0445 \u043a\u043e\u043d\u0441\u0442\u0430\u043d\u0442 PHP:\n<ol>\n<li><code>CASE_UPPER<\/code><\/li>\n<li><code>CASE_LOWER<\/code>(\u0437\u0430 \u0443\u043c\u043e\u0432\u0447\u0430\u043d\u043d\u044f\u043c)<\/li>\n<\/ol>\n<\/li>\n<\/ol>\n<h2>\u041e\u0441\u043e\u0431\u043b\u0438\u0432\u043e\u0441\u0442\u0456 \u0442\u0430 \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u0456 \u043f\u0440\u0438\u043a\u043b\u0430\u0434\u0438<\/h2>\n<h3>\u0417\u043c\u0456\u043d\u0430 \u0440\u0435\u0433\u0456\u0441\u0442\u0440\u0443 \u043a\u043b\u044e\u0447\u0456\u0432 \u043e\u0431\u2019\u0454\u043a\u0442\u0456\u0432<\/h3>\n<p>\u0423 PHP \u0432\u0438 \u043c\u043e\u0436\u0435\u0442\u0435 \u043b\u0435\u0433\u043a\u043e \u043f\u0435\u0440\u0435\u0442\u0432\u043e\u0440\u044e\u0432\u0430\u0442\u0438 \u043e\u0431\u2019\u0454\u043a\u0442\u0438 \u044f\u043a \u043c\u0430\u0441\u0438\u0432\u0438 \u0442\u0430 \u043d\u0430\u0432\u043f\u0430\u043a\u0438, \u0442\u043e\u0436 \u0437\u0430 \u0446\u0456\u0454\u044e \u043b\u043e\u0433\u0456\u043a\u043e\u044e \u0432\u0438 \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u0435\u0440\u0435\u0442\u0432\u043e\u0440\u044e\u0432\u0430\u0442\u0438 \u043a\u043b\u044e\u0447\u0456 \u043e\u0431\u2019\u0454\u043a\u0442\u0430 \u0437\u0430 \u0434\u043e\u043f\u043e\u043c\u043e\u0433\u043e\u044e <code>array_change_key_case<\/code>\u043f\u0440\u043e\u0441\u0442\u043e\u0433\u043e \u043f\u0435\u0440\u0435\u0432\u0435\u0434\u0435\u043d\u043d\u044f \u043e\u0431\u2019\u0454\u043a\u0442\u0430 \u0432 \u043c\u0430\u0441\u0438\u0432 \u0456 \u043d\u0430\u0437\u0430\u0434.<\/p>\n<pre><code>$object              = new StdClass();\n$object-&gt;ID          = 42;\n$object-&gt;POST_STATUS = 'publish';\n$lower_case_object   = (object) array_change_key_case( (array) $object, CASE_LOWER );\nprint_r( $lower_case_object ); \n<\/code><\/pre>\n<p>\u0423 \u043d\u0430\u0432\u0435\u0434\u0435\u043d\u043e\u043c\u0443 \u0432\u0438\u0449\u0435 \u043f\u0440\u0438\u043a\u043b\u0430\u0434\u0456 \u043c\u0438 \u0441\u0442\u0432\u043e\u0440\u044e\u0454\u043c\u043e \u043e\u0431\u2019\u0454\u043a\u0442 \u0456\u0437 \u043a\u043b\u0430\u0432\u0456\u0448\u0430\u043c\u0438 \u0432\u0435\u0440\u0445\u043d\u044c\u043e\u0433\u043e \u0440\u0435\u0433\u0456\u0441\u0442\u0440\u0443, \u0430 \u043f\u043e\u0442\u0456\u043c \u043f\u0435\u0440\u0435\u0442\u0432\u043e\u0440\u044e\u0454\u043c\u043e \u0439\u043e\u0433\u043e \u043d\u0430 \u0432\u0438\u043a\u043e\u0440\u0438\u0441\u0442\u0430\u043d\u043d\u044f \u043a\u043b\u0430\u0432\u0456\u0448 \u043d\u0438\u0436\u043d\u044c\u043e\u0433\u043e \u0440\u0435\u0433\u0456\u0441\u0442\u0440\u0443.<\/p>\n<h2>\u041f\u043e\u0434\u0430\u043b\u044c\u0448\u0435 \u0447\u0438\u0442\u0430\u043d\u043d\u044f<\/h2>\n<p>\u0429\u043e\u0431 \u043e\u0442\u0440\u0438\u043c\u0430\u0442\u0438 \u0434\u043e\u0434\u0430\u0442\u043a\u043e\u0432\u0456 \u0432\u0456\u0434\u043e\u043c\u043e\u0441\u0442\u0456, \u0432\u0438 \u043c\u043e\u0436\u0435\u0442\u0435 \u043f\u0435\u0440\u0435\u0433\u043b\u044f\u043d\u0443\u0442\u0438 <a href=\"https:\/\/www.php.net\/manual\/en\/function.array-change-key-case.php\" target=\"_blank\" rel=\"noopener nofollow\" class=\"external external_icon\">\u043f\u043e\u0441\u0456\u0431\u043d\u0438\u043a PHP<\/a>.<\/p>\n<p><div id=\"PostUnique_PostSource\" style=\"padding-top: 50px\">\u0414\u0436\u0435\u0440\u0435\u043b\u043e \u0437\u0430\u043f\u0438\u0441\u0443:  <a target=\"_blank\" rel=\"noopener nofollow\" href=\"\/\/wholesomecode.ltd\" class=\"external external_icon\">wholesomecode.ltd<\/a><\/div><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u0417\u043c\u0456\u043d\u0430 \u0440\u0435\u0433\u0456\u0441\u0442\u0440\u0443 \u043a\u043b\u044e\u0447\u0430 \u043c\u0430\u0441\u0438\u0432\u0443 (array_change_key_case) \u2014 \u0446\u0435 \u043f\u0440\u043e\u0441\u0442\u0430 \u0444\u0443\u043d\u043a\u0446\u0456\u044f, \u0429\u041e \u0434\u043e\u0437\u0432\u043e\u043b\u044f\u0454 \u0432\u0430\u043c \u0437\u0440\u043e\u0431\u0438\u0442\u0438 \u0432\u0441\u0456 \u043a\u043b\u044e\u0447\u0456 \u0432\u0430\u0448\u043e\u0433\u043e \u043c\u0430\u0441\u0438\u0432\u0443 \u0432\u0435\u043b\u0438\u043a\u0438\u043c\u0438 \u0447\u0438 \u043d\u0438\u0436\u043d\u0456\u043c\u0438 \u043b\u0456\u0442\u0435\u0440\u0430\u043c\u0438.<\/p>\n","protected":false},"author":1,"featured_media":223774,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":"","_wp_rev_ctl_limit":""},"categories":[808,849,725],"tags":[1174],"class_list":["post-228391","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-php-10","category-pidruchnyky","category-rozrobnyk","tag-affiai-uk"],"_links":{"self":[{"href":"https:\/\/wordpress.mediadoma.com\/uk\/wp-json\/wp\/v2\/posts\/228391","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/wordpress.mediadoma.com\/uk\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wordpress.mediadoma.com\/uk\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wordpress.mediadoma.com\/uk\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/wordpress.mediadoma.com\/uk\/wp-json\/wp\/v2\/comments?post=228391"}],"version-history":[{"count":0,"href":"https:\/\/wordpress.mediadoma.com\/uk\/wp-json\/wp\/v2\/posts\/228391\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/wordpress.mediadoma.com\/uk\/wp-json\/wp\/v2\/media\/223774"}],"wp:attachment":[{"href":"https:\/\/wordpress.mediadoma.com\/uk\/wp-json\/wp\/v2\/media?parent=228391"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wordpress.mediadoma.com\/uk\/wp-json\/wp\/v2\/categories?post=228391"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wordpress.mediadoma.com\/uk\/wp-json\/wp\/v2\/tags?post=228391"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}