https://www.ads-software.com/support/topic/auto-generated-username-ultimatemember/
But it didn’t work for me. I use the same code, only in my case the meta key is called verein_name. However, the user name is always saved as the standard combination: firstnamelastname
Has the procedure changed here?
This is my code in the functions.php:
add_action("um_registration_complete","um_042121_change_user_role", 1, 2 );
function um_042121_change_user_role( $user_id, $args ){
try {
if( isset( $args['verein_name'] ) ){
wp_update_user( array( 'ID' => $user_id, 'user_login' => $args['verein_name'] ) );
} else {
wp_update_user( array( 'ID' => $user_id, 'user_login' => $args['last_name'].'-'.$args['first_name'] ) );
}
}
catch(Exception $e) {
echo 'Message: ' .$e->getMessage();
}
}
Am I missing something?
Thanks in advance
First off, thanks so much for this incredible plugin. Once this issue is resolved I’ll absolutely give you a perfect rating. There’s one thing holding me back though, and it’s a big one.
No matter what I do, each section only gets a single paragraph. I have tried generating 2 sections all the way to 8. The number of paragraphs per section is defaulted to 3. I’ve changed it to every number available, yet no matter what I get a short paragraph for each heading.
I’ve expanded the options and removed the {PARAGRAPHS_PER_SECTION} and replaced it with numbers 2-8, but nothing ever changes it away from 1.
I have also tried to do bulk creation, and it does the same thing – just one single paragraph per heading (or section).
I searched the forum here and saw someone else had the same issue a few months back, but I didn’t see how it was resolved.
There’s a chance I’m incorrectly making assumptions, but it seems like something’s happening wrong. I’m also not seeing anything that gives any evidence that “===INTRO: ” or “===OUTRO: ” are happening, but again I could just be missing something (as I’m not really sure what that’s supposed to do).
Would love any input!
]]>=======
[02-Apr-2023 20:14:06 UTC] PHP Fatal error: Uncaught Error: Undefined constant “SUCURISCAN_API_URL” in /home/******/public_html/wp-content/plugins/sucuri-scanner/src/api.lib.php:232
Stack trace:
0 /home/******/public_html/wp-content/plugins/sucuri-scanner/src/api.lib.php(342): SucuriScanAPI::apiCallWordpress()
1 /home/******/public_html/wp-content/plugins/sucuri-scanner/src/settings-general.php(104): SucuriScanAPI::registerSite()
2 /home//public_html/wp-content/plugins/sucuri-scanner/src/pagehandler.php(133): sucuriscan_settings_general_apikey()
3 /home/******/public_html/wp-includes/class-wp-hook.php(308): sucuriscan_settings_page()
4 /home/******/public_html/wp-includes/class-wp-hook.php(332): WP_Hook->apply_filters()
5 /home/******/public_html/wp-includes/plugin.php(517): WP_Hook->do_action()
6 /home/******/public_html/wp-admin/admin.php(259): do_action()
7 {main}
thrown in /home/******/public_html/wp-content/plugins/sucuri-scanner/src/api.lib.php on line 232
============
Please assist.
]]>