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
/** | |
* Set status 'awaiting_admin_review' after the Email verification | |
*/ | |
function my_activate_account_via_email_link() { | |
if ( isset( $_REQUEST['act'] ) && $_REQUEST['act'] == 'activate_via_email' && isset( $_REQUEST['hash'] ) && is_string( $_REQUEST['hash'] ) && strlen( $_REQUEST['hash'] ) == 40 && | |
isset( $_REQUEST['user_id'] ) && is_numeric( $_REQUEST['user_id'] ) ) { // valid token | |
$user_id = absint( $_REQUEST['user_id'] ); | |
delete_option( "um_cache_userdata_{$user_id}" ); | |
um_fetch_user( $user_id ); |
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 | |
/** | |
* This code shows default field value on "view" mode if field value is empty in the Profile form of the Ultimate Member. | |
* | |
* You can add this code to the end of the file functions.php in the active theme (child theme) directory. | |
* | |
* Ultimate Member documentation: https://docs.ultimatemember.com/ | |
* Ultimate Member support (for customers): https://ultimatemember.com/support/ticket/ | |
*/ |
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 | |
/** | |
* This example shows how to add a new tab into the Profile page of the Ultimate Member. | |
* See the article https://docs.ultimatemember.com/article/69-how-do-i-add-my-extra-tabs-to-user-profiles | |
* | |
* This example adds the tab 'mycustomtab' that contains the field 'description'. You can add your own tabs and fields. | |
* Important! Each profile tab has an unique key. Replace 'mycustomtab' to your unique key. | |
* | |
* You can add this code to the end of the file functions.php in the active theme (child theme) directory. |
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 | |
/** | |
* This example shows how to add custom Account tab with WooCommerce fields in Ultimate Member. | |
* See the article https://docs.ultimatemember.com/article/1504-how-to-add-custom-woocommerce-fields-to-account | |
* | |
* This example adds the tab 'wc_custom' that contains the field 'wc_custom_01'. You can add your own tabs and fields. | |
* Important! Each account tab has an unique key. Replace 'wc_custom' to your unique key. | |
* | |
* You can add this code to the end of the file functions.php in the active theme directory. |
NewerOlder