cipf v 0.4.1 wip trying to filter registration email
This commit is contained in:
@@ -89,6 +89,7 @@ function replace_words($matches, $user_id = null) {
|
||||
function filter_email_wp($args) {
|
||||
// pattern : anything surrounded by '$$', ex : $$value$$
|
||||
$pattern = '/\$\$(.*?)\$\$/';
|
||||
error_log("args: " . json_encode($args));
|
||||
|
||||
$old_body = $args['message'];
|
||||
$new_body = preg_replace_callback($pattern, __NAMESPACE__.'\replace_words', $old_body);
|
||||
|
||||
@@ -32,7 +32,10 @@ function return_result($output) {
|
||||
* format the output
|
||||
* if is acf, use acf default format
|
||||
*/
|
||||
function format_user_info($query, &$current_user, $user_id) {
|
||||
function format_user_info($query, $current_user, $user_id) {
|
||||
error_log("query: " . json_encode($query));
|
||||
error_log("current_user: " . json_encode($current_user));
|
||||
error_log("user_id: " . json_encode($user_id));
|
||||
$output_date_format = Custer::USER_INFO_DATE_FORMAT;
|
||||
|
||||
$is_acf = false;
|
||||
|
||||
Reference in New Issue
Block a user