25 lines
536 B
PHP
25 lines
536 B
PHP
<?php
|
|
|
|
/*
|
|
* it means someone outside wp is accessing the file, in this case kill it.
|
|
*/
|
|
if (!defined('ABSPATH')) {
|
|
die('You can not access this file!');
|
|
}
|
|
|
|
|
|
|
|
/*
|
|
function reset_some_fields_CIPF($form_id, $user_id, $post_array) {
|
|
*/
|
|
function reset_some_fields_CIPF() {
|
|
$user_id = get_current_user_id();
|
|
update_field('cgv', array(""), 'user_'.$user_id);
|
|
update_field('paiement', array(""), 'user_'.$user_id);
|
|
update_field('livraison', array(""), 'user_'.$user_id);
|
|
}
|
|
add_action('df_after_insert_user', 'reset_some_fields_CIPF');
|
|
|
|
|
|
?>
|