[themes] How do I remove a theme from drupal

Nat Meysenburg nat at openflows.com
Tue Aug 16 19:07:21 UTC 2011


On 08/13/2011 11:56 PM, Anton Lukichjow wrote:
> No files in a directory /sites/all/themes, the theme is displayed in Admin panel.

It may depend on what theme you are trying to remove.

Are you speaking of one of the core themes (eg: Bartik and Garland)?
They would certainly not be in the "sites/all/themes",
"sites/default/themes" or "sites/SITEURL/theme" and would definitely
still show up in the admin options, because they are core themes.

To remove them, you would have to remove the files for the core themes
that you don't want -- or less destructively, rename their .info files
to .info.off (or some other fake file extension that isn't .info). This
goes against one of the top rules of Drupal best practices; "don't hack
core."  If you do remove those themes, they will no longer show up on
the admin page. However, they will come back with the next site update,
since they are part of the core package.

If you are committed to doing this, be aware that you gain little more
than cleaning up a page nobody looks at after site development. Unless
you are attempting to repackage/fork Drupal, all this approach really
accomplishes in the end is ensuring that you do more work for every core
security update.

I do not recommend this course of action, but have had clients do this
on there own, and it worked out okay for them.

~~nat


More information about the themes mailing list