Last active
June 21, 2019 19:37
-
-
Save dparker1005/d2a159c8dda39baafc868ffdf498d0f9 to your computer and use it in GitHub Desktop.
Adds user meta fields to 'Export Personal Data' and 'Delete Personal Data' for GDPR compliance, particularly with Register Helper add-on
This file contains 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 | |
function my_pmpro_add_personal_data_fields( $fields ) { | |
$fields['meta_name'] = 'Pretty Meta Name'; | |
// Copy the above line for each field you want to include. | |
return $fields; | |
} | |
add_filter( 'pmpro_get_personal_user_meta_fields', 'my_pmpro_add_personal_data_fields' ); | |
function my_pmpro_add_personal_data_fields_to_erase( $fields ) { | |
$fields[] = 'meta_name'; | |
// Copy the above line for each field you want deleted. | |
return $fields; | |
} | |
add_filter( 'pmpro_get_personal_user_meta_fields_to_erase', 'my_pmpro_add_personal_data_fields_to_erase' ); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment