Some of my pages have a lot of revisions. (over 50). I want to limit revisions to 20 for each page.

I added the following to my wp-config file:

define(‘WP_POST_REVISIONS’, 20);

I expected that this would keep 20 revisions for each page and delete the older revisions. However, this has not deleted my old revisions. Does this new setting only apply to new pages? What is a good way I can delete old revisions past 20?