Entry Approval Merge Tags or how to approve an entry via email
To enable users to moderate entries from form notifications, you can use entry moderation Merge Tags, added in GravityView 2.17. The Merge Tags are replaced in the notification emails with links to approve, disapprove, or reset an entry's approval.
Merge Tags
{gv_approve_entry}
Link to approve an entry{gv_disapprove_entry}
Link to disapprove an entry{gv_unapprove_entry}
Link to unapprove an entry (reset approval)
Modifiers
:[\d+d|h|m|s]
Number followed by unit (d
day,h
hour,m
minute,s
second) of hours the approval link is valid for.24h
by default.:public
Make the link clickable by anyone, even users who are logged-out. (Requires the "Enable Public Entry Moderation" GravityView setting or per-form setting to be enabled).:url
Just output the URL of the approval action. Useful when creating custom approval links.
Example usage
{gv_approve_entry}
- Valid for default (24 hours). Private.{gv_approve_entry:48h}
- Valid for 48 hours. Private.{gv_approve_entry:20m}
- valid for 20 minutes. Private.{gv_approve_entry:public}
- Valid for default (24 hours), public{gv_approve_entry:2h:public}
- valid for 2 hours, public{gv_approve_entry:20m:public}
- valid for 20 minutes, public<a href="{gv_approve_entry:url}">Accept this submission</a>
<a href="{gv_disapprove_entry:url}">Ignore this submission</a>
<a href="{gv_unapprove_entry:url}">Pending verification</a>
The same usage pattern applies for {gv_disapprove_entry}
and {gv_unapprove_entry}
Merge Tags.
Permissions
For these Merge Tags to work, the "Enable Public Entry Moderation" option must be activated on GravityKit's Settings page > GravityView tab:
Security
Tokens are in JWT format. The secret used to generate the token is wp_salt('auth')
.