{"id":87291,"date":"2011-10-26T08:00:00","date_gmt":"2011-10-26T08:00:00","guid":{"rendered":"https:\/\/www.weixiaoduo.com\/plugins\/2024\/02\/22\/htaccess-secure-files\/"},"modified":"2012-06-08T15:14:00","modified_gmt":"2012-06-08T15:14:00","slug":"htaccess-secure-files","status":"publish","type":"post","link":"https:\/\/www.weixiaoduo.com\/plugins\/htaccess-secure-files\/","title":{"rendered":"Htaccess Secure Files"},"content":{"rendered":"<p><strong>The Htaccess Secure Files plugin can only be activated on Apache web servers with mod_rewrite enabled, and will automatically raise an error upon activation if this is not the case.<\/strong><\/p>\n<p>The Htaccess Secure Files plugin allows for setting files to be accessible only to visitors who have a specified IP address or <a title=\"WordPress role or capbility\" href=\"https:\/\/codex.wordpress.org\/Roles_and_Capabilities\" rel=\"nofollow ugc\">WordPress role or capability<\/a>. By using <a title=\".htaccess files\" href=\"http:\/\/en.wikipedia.org\/wiki\/Htaccess\" rel=\"nofollow ugc\">.htaccess files<\/a> to secure the content instead of a separate directory outside the web root, WordPress\u2019s native media library functionality can be used to upload secure files and link to them from within the visual editor.<\/p>\n<p>By default all built-in WordPress roles will be allowed to access content that is marked as secure. The Settings -> Secure Files admin screen controls which roles, capabilities, and IP addresses are allowed to view or download secured files. If a custom role or capability is desired, there are several <a title=\"WordPress plugins\" href=\"https:\/\/wordpress.org\/extend\/plugins\/search.php?q=roles+capabilities\" rel=\"ugc\">WordPress plugins<\/a> capable of creating and editing roles and capabilities.<\/p>\n<p><strong>Any visitor that matches any selected role, capability, or IP address will be allowed to access secured files.<\/strong><\/p>\n<p>This plugin works by creating a .htaccess files in the directory of each secured file. If you manually edit the .htaccess file and it becomes corrupt (a 500 Internal Server Error is the most likely symptom), I recommend deleting the .htaccess file and then edit and save each secured item in the media library.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Allows securing files in WP's media library to be only accessible to users with specific roles, capabilities, or IP addresses.<\/p>\n","protected":false},"author":65,"featured_media":290600,"comment_status":"open","ping_status":"","sticky":false,"template":"","format":"standard","meta":{"slim_seo":{"title":"Htaccess Secure Files - \u8587\u6653\u6735\u63d2\u4ef6\u76ee\u5f55","description":"Allows securing files in WP's media library to be only accessible to users with specific roles, capabilities, or IP addresses."},"footnotes":""},"categories":[1],"tags":[2216,238,30],"class_list":["post-87291","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-uncategorized","tag-htaccess","tag-media","tag-secure"],"_links":{"self":[{"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/posts\/87291","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/users\/65"}],"replies":[{"embeddable":true,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/comments?post=87291"}],"version-history":[{"count":0,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/posts\/87291\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/media\/290600"}],"wp:attachment":[{"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/media?parent=87291"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/categories?post=87291"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.weixiaoduo.com\/plugins\/wp-json\/wp\/v2\/tags?post=87291"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}