{"id":1034,"date":"2013-08-23T18:02:54","date_gmt":"2013-08-23T18:02:54","guid":{"rendered":"http:\/\/musilda.cz\/?p=1034"},"modified":"2013-08-23T18:02:54","modified_gmt":"2013-08-23T18:02:54","slug":"jak-rozsirit-povolene-html-tagy-wordpress-formular","status":"publish","type":"post","link":"https:\/\/affinite.io\/cs\/jak-rozsirit-povolene-html-tagy-wordpress-formular\/","title":{"rendered":"Jak roz\u0161\u00ed\u0159it povolen\u00e9 html tagy ve WordPress koment\u00e1\u0159i"},"content":{"rendered":"\n
Ji\u017e v z\u00e1kladu povoluje WordPress pou\u017eit\u00ed n\u011bkolika html tag\u016f v koment\u00e1\u0159\u00edch. Jak ale roz\u0161\u00ed\u0159it povolen\u00e9 tagy, jako jsou <a>, <pre> a dal\u0161\u00ed? Pomoc\u00ed jednoduch\u00e9 funkce definujeme povolen\u00e9 tagy.<\/p>\n\n\n\n\n\n\n\n
Do functions.php vlo\u017e\u00edme n\u00e1sleduj\u00edc\u00ed k\u00f3d:<\/p>\n\n\n\n
function our_allow_tags() {\n global $allowedtags;\n $allowedtags['pre'] = array('class'=>array('pole jednotliv\u00fdch povolen\u00fdch tag\u016f'));\n}\nadd_action('comment_post', 'our_allow_tags');\n<\/pre>\n\n\n\nDo pole na t\u0159et\u00edm \u0159\u00e1dku vlo\u017ete v\u0161echny tagy, kter\u00e9 chcte v koment\u00e1\u0159\u00edch povolit.<\/p>\n","protected":false},"excerpt":{"rendered":"
Ji\u017e v z\u00e1kladu povoluje WordPress pou\u017eit\u00ed n\u011bkolika html tag\u016f v koment\u00e1\u0159\u00edch. Jak ale roz\u0161\u00ed\u0159it povolen\u00e9 tagy, jako jsou <a>, <pre> a dal\u0161\u00ed? Pomoc\u00ed jednoduch\u00e9 funkce definujeme povolen\u00e9 tagy.<\/p>\n","protected":false},"author":1,"featured_media":8624,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[19],"tags":[71],"class_list":["post-1034","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-snippety","tag-allowed-tags"],"_links":{"self":[{"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/posts\/1034"}],"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=1034"}],"version-history":[{"count":0,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/posts\/1034\/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=1034"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/categories?post=1034"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/tags?post=1034"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}