Created
August 20, 2014 21:15
-
-
Save spivurno/17b58a9cd6c67f5929b4 to your computer and use it in GitHub Desktop.
Gravity Wiz // Gravity Perks // GP Nested Forms // Customize the Item Labels (i.e. "Add Entry", "View Entry")
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <?php | |
| // basic usage | |
| add_filter( 'gpnf_item_labels', 'my_item_labels' ); | |
| function my_item_labels() { | |
| return array( | |
| 'singular' => __( 'employee', 'gravityperks' ), | |
| 'plural' => __( 'employees', 'gravityperks' ) | |
| ); | |
| } | |
| // form-specific usage | |
| add_filter( 'gpnf_item_labels_1', 'my_item_labels_for_form_id_1' ); | |
| function my_item_labels_for_form_id_1() { | |
| return array( | |
| 'singular' => __( 'employee', 'gravityperks' ), | |
| 'plural' => __( 'employees', 'gravityperks' ) | |
| ); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Curious if the GP Nested Forms is going to be added to the available perks anytime soon? Thanks.