Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

gpfr-apply-rename-to-every-field.php: Added snippet to apply GPFR to every field, no matter if there is an existing template value or not. #701

Merged
merged 2 commits into from
Sep 28, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 15 additions & 0 deletions gp-file-renamer/gpfr-apply-rename-to-every-field.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php
/**
* Gravity Perks // File Renamer // Apply Rename to Every Field
* https://gravitywiz.com/documentation/gravity-forms-file-renamer/
*
* This applies GPFR to every single field, no matter if there is a "template value" set for the field or not.
*
* This is useful when combined with "gpfr_filename_template" filter to automatically apply the filtered template
* to all fields.
*
* Requires GP File Renamer v1.0.6+
*/
add_filter( 'gpfr_is_applicable_field', function ( $should_apply_gpfr, $form, $field ) {
return true;
}, 10, 3 );
Loading