[wp-hackers] best way to reset the database

Haluk Karamete halukkaramete at gmail.com
Wed Apr 4 03:29:55 UTC 2012


I'm working with a fresh install programmatically.

I create taxonomies, terms, posts, on the fly without the dashboard. It's a
process for me with lots of trials and errors.
Many times, I want to start with a fresh slate.

That's where the question is formed. What's the most effective way to bring
the wp to the starting ( well, almost starting ) phase, programmatically?

If I drop the database with a mysql statement, wp would create the tables
and that would give me a fresh slate but that would also blow the bloginfo
and admin user etc.

All I care is to clean the wp_post, post_meta, where terms and taxonomies
stored. no need to clean the options table.
If I delete the records, that does not help cause then my IDs won't start
from 0.

What's a good way to handle this?


More information about the wp-hackers mailing list