WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a folder inside my plugin that's used to store cached data for the application.

There's no need for the user to edit these files so I'd like to remove this folder's files from appearing in the "Plugin files" listing that appears in the right sidebar when editing the plugin files via "Plugins > Editor".

Is this possible?

share|improve this question
As far as i'm aware there's no way to exclude files from the plugin editor, there's only support for disabling it, but no way to selectively exclude files/folders or specific plugins. – Mark Duncan Aug 17 '11 at 21:01
up vote 4 down vote accepted

Use the upload directory to store files.

You should never store files in the plugin directory. There is no guarantee that you have write access there.

share|improve this answer
Good call. Just to add a detail for the OP: you can easily determine which is the uploads dir using wp_upload_dir(). – MathSmath Aug 17 '11 at 22:58
As an additional point of interest on this topic, some server configurations are vulnerable to code injection if the attacker figures out how to put custom code into your cache file. – Annika Backstrom Aug 18 '11 at 3:19

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.