Feature request: Delete theme

Discussion corner for Developers of Serendipity.
Post Reply
User avatar
Don Chambers
Regular
Posts: 3628
Joined: Mon Feb 13, 2006 3:40 am
Location: Chicago, IL, USA
Contact:

Feature request: Delete theme

Post by Don Chambers » Wed Mar 11, 2015 8:24 pm

I know I can delete themes by deleting the corresponding folder via ftp.... but that still leaves everything in the options table. How about a button that not only deletes the files, but also deletes everything from the options table, so there is no trace of ever having used the theme?

This would be especially helpful when developing new themes, so I can purge everything from the table, and see what a fresh install would look like again. Also helpful when experimenting with several different themes. For instance yesterday, I must have installed about 2 dozen different themes. A one-button click solution would be nice to have.

Is this possible?

User avatar
garvinhicking
Core Developer
Posts: 30014
Joined: Tue Sep 16, 2003 9:45 pm
Location: Cologne, Germany
Contact:

Re: Feature request: Delete theme

Post by garvinhicking » Thu Mar 12, 2015 11:07 am

Hi!

Hm, not sure we really need a maintenance option for that, because it's very developer centric and doesn't really occur a lot for normal users to matter.

I'd rather suggest you simply use a tool like adminer or phpMyAdmin to execute:

Code: Select all

DELETE FROM serendipity_options WHERE okey = 't_XXX'
(replace XXX with the templatename)

For the end user I personally find it helpful to preserve options, if a template is later on re-used, to have the same options like before. It doesn't really impact a database to have a few hundred rows lieing around... even though I understand the intention for it. ;)
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/

User avatar
Don Chambers
Regular
Posts: 3628
Joined: Mon Feb 13, 2006 3:40 am
Location: Chicago, IL, USA
Contact:

Re: Feature request: Delete theme

Post by Don Chambers » Thu Mar 12, 2015 4:01 pm

Thanks - I'll use phpmyadmin for that.

Post Reply