{"id":9796,"date":"2013-04-04T18:34:04","date_gmt":"2013-04-04T18:34:04","guid":{"rendered":"http:\/\/musilda.cz\/?p=43"},"modified":"2013-04-04T18:34:04","modified_gmt":"2013-04-04T18:34:04","slug":"vypnuti-standardnich-widgetu","status":"publish","type":"post","link":"https:\/\/affinite.io\/cs\/vypnuti-standardnich-widgetu\/","title":{"rendered":"Vypnut\u00ed standardn\u00edch widget\u016f"},"content":{"rendered":"\n

N\u011bkdy se st\u00e1v\u00e1, \u017ee p\u0159ipravujete jednoduchou \u0161ablonu pro klienta, kter\u00fd wordpressu moc nerozum\u00ed a hodilo by se v\u00e1m potla\u010dit n\u011bkter\u00e9 widgety, kter\u00e9 m\u00e1 po instalaci \u0161ablony k dispozici. K tomu vyu\u017eijeme funkci unregister_widget() .<\/p>\n\n\n\n\n\n\n\n

Vytvo\u0159\u00edme si funkci, kterou vlo\u017e\u00edme do function.php a m\u00e1me hotovo<\/p>\n\n\n\n

\n

function unregister_default_wp_widgets() {<\/p>\n\n\n\n

unregister_widget(‚WP_Widget_Calendar‘);<\/p>\n\n\n\n

unregister_widget(‚WP_Widget_Search‘);<\/p>\n\n\n\n

unregister_widget(‚WP_Widget_Recent_Comments‘);<\/p>\n\n\n\n

}<\/p>\n\n\n\n

add_action(‚widgets_init‘, ‚unregister_default_wp_widgets‘, 1);<\/p>\n<\/blockquote>\n","protected":false},"excerpt":{"rendered":"

N\u011bkdy se st\u00e1v\u00e1, \u017ee p\u0159ipravujete jednoduchou \u0161ablonu pro klienta, kter\u00fd wordpressu moc nerozum\u00ed a hodilo by se v\u00e1m potla\u010dit n\u011bkter\u00e9 widgety, kter\u00e9 m\u00e1 po instalaci \u0161ablony k dispozici. K tomu vyu\u017eijeme funkci unregister_widget() .<\/p>\n","protected":false},"author":1,"featured_media":8624,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12,19,30],"tags":[354,413,460],"class_list":["post-9796","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-navody","category-snippety","category-wordpress","tag-snipet","tag-widget","tag-wordpress-2"],"_links":{"self":[{"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/posts\/9796"}],"collection":[{"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/comments?post=9796"}],"version-history":[{"count":0,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/posts\/9796\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/media\/8624"}],"wp:attachment":[{"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/media?parent=9796"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/categories?post=9796"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/tags?post=9796"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}