Obsah souboru<\/strong><\/li>\n<\/ol>\n\n\n\nEditor souboru pluginu funguje trochu odli\u0161n\u011b oproti p\u0159ede\u0161l\u00e9mu editoru \u0161ablony. Rozd\u00edl najdeme v tom, \u017ee u plugin\u016f nen\u00ed mo\u017enost vytvo\u0159it „child verzi“, a proveden\u00e9 zm\u011bny se p\u0159i aktualizaci p\u0159ep\u00ed\u0161ou.<\/p>\n\n\n\n
Rozhodn\u011b bychom se m\u011bli vyvarovat vytv\u00e1\u0159en\u00ed kopie pluginu s ulo\u017een\u00fdmi zm\u011bnami, proto\u017ee by nedost\u00e1val aktualizace a ohro\u017eoval by bezpe\u010dnost webu. Nejlep\u0161\u00ed mo\u017en\u00e9 \u0159e\u0161en\u00ed pro \u00fapravu soubor\u016f pluginu si uk\u00e1\u017eeme n\u00ed\u017ee.<\/p>\n\n\n\n
Pokud na webu pou\u017e\u00edv\u00e1me spr\u00e1vn\u011b nak\u00f3dovan\u00fd plugin, v\u00fdvoj\u00e1\u0159i jist\u011b mysleli na p\u0159\u00edpadn\u00e9 \u00fapravy, a vyu\u017eili tzv. hook\u016f, pomoc\u00ed kter\u00fdch budeme schopni upravit funkcionalitu pluginu bez ztr\u00e1ty zm\u011bn p\u0159i ka\u017ed\u00e9 aktualizaci.<\/p>\n\n\n\n
Dal\u0161\u00edm zp\u016fsobem vyu\u017eit\u00ed editoru m\u016f\u017ee b\u00fdt v\u00fdvoj vlastn\u00edho pluginu, kdy se ulo\u017een\u00e9 zm\u011bny v k\u00f3du instantn\u011b aplikuj\u00ed, co\u017e n\u00e1m m\u016f\u017ee u\u0161et\u0159it \u010das, kter\u00fd bychom ztr\u00e1celi neust\u00e1l\u00fdm manu\u00e1ln\u00edm p\u0159esouv\u00e1n\u00edm souboru.<\/p>\n\n\n\n
Jak deaktivovat editor soubor\u016f WordPressu?<\/h2>\n\n\n\n
Pokud by na webu bylo nap\u0159\u00edklad v\u00edce u\u017eivatel\u016f s admin pr\u00e1vy (typicky klient), m\u016f\u017ee b\u00fdt nejlep\u0161\u00ed zak\u00e1zat p\u0159\u00edstup k editoru soubor\u016f, \u010d\u00edm\u017e p\u0159edejdeme necht\u011bn\u00fdm chyb\u00e1m. Ne v\u017edy si toti\u017e u\u017eivatel uv\u011bdomuje potenci\u00e1ln\u00ed rizika spojen\u00e1 s \u00fapravou k\u00f3du. <\/p>\n\n\n\n
Pro deaktivaci defaultn\u00edho editoru soubor\u016f WordPressu p\u0159id\u00e1me pomoc\u00ed FTP klienta do souboru wp-config.php<\/strong> n\u00e1sleduj\u00edc\u00ed k\u00f3d:<\/p>\n\n\n\ndefine('DISALLOW_FILE_EDIT', true);<\/code><\/pre>\n\n\n\nK\u00f3d odebere pr\u00e1va pro editaci soubor\u016f v\u0161em u\u017eivatel\u016fm (v\u010detn\u011b admin\u016f). Pro povolen\u00ed sta\u010d\u00ed op\u011bt p\u0159ej\u00edt do souboru a smazat vlo\u017een\u00fd \u0159\u00e1dek k\u00f3du.<\/p>\n","protected":false},"excerpt":{"rendered":"
\u010cas od \u010dasu je pot\u0159eba p\u0159izp\u016fsobit si \u0161ablonu WordPressu, p\u0159idat vlastn\u00ed funkce apod. Soubory samoz\u0159ejm\u011b m\u016f\u017eeme editovat p\u0159es FTP, ale d\u00edky vestav\u011bn\u00e9mu WordPress n\u00e1stroji jsme schopni upravovat soubory webu p\u0159\u00edmo z na\u0161eho prohl\u00ed\u017ee\u010de. Podporov\u00e1ny jsou pouze soubory v n\u00e1sleduj\u00edc\u00edch form\u00e1tech: HTML, PHP, CSS a TXT. Editor soubor\u016f ve WordPressu K dispozici m\u00e1me dva r\u016fzn\u00e9 editory,<\/p>\n","protected":false},"author":1,"featured_media":9133,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"rank_math_lock_modified_date":false,"footnotes":""},"categories":[30],"tags":[460],"class_list":["post-9131","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-wordpress","tag-wordpress-2"],"_links":{"self":[{"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/posts\/9131"}],"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=9131"}],"version-history":[{"count":0,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/posts\/9131\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/media\/9133"}],"wp:attachment":[{"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/media?parent=9131"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/categories?post=9131"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/affinite.io\/cs\/wp-json\/wp\/v2\/tags?post=9131"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}