Unapproving entries automatically after they're edited
When allowing logged in users to edit entries they created by checking the "Allow User Edit" box in View Settings, you also have the option to automatically unapprove entries after they've been edited:
By default, only edits made by non-administrators will reset the approval status to "Unapproved."
If you would prefer to have the status reset to "Unapproved" when any user or administrator edits an entry, you can do that by adding the following code to your theme's functions.php file:
If you're not sure where to put code sample, please see the following article: Where to put code samples
Advanced information about the Unapprove Entries After Edit functionality:
GravityView's autounapprove feature is only called if all of these conditions are met:
- The user is editing from the frontend (specifically via the gravityview/edit_entry/after_update action)
- With the "Unapprove Entries After Edit " feature enabled for the View
- The user is not an administrator (they do not have
gravityview_moderate_entries
capability) - The
gravityview/approve_entries/autounapprove/status
filter is not set anywhere tofalse