Skip to content

Instantly share code, notes, and snippets.

@greenhornet79
Last active February 9, 2022 21:34
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save greenhornet79/2a2089204c6a1be55d3421dd22737a8a to your computer and use it in GitHub Desktop.
Save greenhornet79/2a2089204c6a1be55d3421dd22737a8a to your computer and use it in GitHub Desktop.
<?php
add_filter('leaky_paywall_simplecirc_subscriber_data', 'zeen_tester_add_phone');
function zeen_tester_add_phone( $data )
{
// this is the name of the field generated by the Leaky Paywall Custom Registration Fields add-on.
// Please change the field name to whatever is being used in your own custom field for phone number.
if ( !isset($_POST['0_field_1_1'] ) ) {
return $data;
}
$data['phone'] = sanitize_text_field( $_POST['0_field_1_1']);
return $data;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment