1

I'd like to clean up unused text formats on some D7 sites. So I need to know which formats are not used. I tried using VBO for this, but there is no field Content: Text format I can add there.

What's a good way to get an overview of formats in use? I'd be ok with using drush for this and I can settle with just knowing the nodes and blocks that use a specific format (ignoring other places like views headers).

I'm not looking for a generic answer like "it's stored in these and these database tables". I'm looking for a practical solution that I can use on many Drupal sites.

1

Use this module: https://www.drupal.org/project/text_formats_report

The module pages says don't use this on production.

3

This is stored on a per-field basis.

Take a look at your database, any field_data_* table. In those tables, the field_X_format column will contain the input format.

  • Some people consider this a useful answer but I don't think it's very practical. Can you turn this into a practical solution? – kqw Feb 13 '15 at 14:55
  • the practical solution is to write a module that does this. that's a very, very broad scope to answer here. – user5482 Feb 13 '15 at 15:06
1

It's hard to clean up old text formats, they are in multiple tables, including the field_revision_* tables.

A better strategy is often just to not use them - only the super admins will see them if you remove permissions from everyone. The only downside of this is that any content using those input filters will become uneditable by everyone else.

It does sound like a problem that a drush command would be useful for.

  • "just to not use them" is not a solution for an active site that's a couple of years old. – kqw Feb 13 '15 at 14:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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