Support » Plugin: Theme My Login » ERROR: Please Enter a Nickname

  • Resolved ScottieDFLH

    (@scottiedflh)


    Hello, I have version 6.4.3 of Theme My Login with WP version 4.4.1. I’m pretty sure the issue I have is due to the latest WP upgrade, but didn’t know about it until one of my users informed me.

    When someone tries to make ANY changes to their profile, they get the following error:

    ERROR: Please Enter A Nickname

    Here is the URL:

    Your Profile

    I don’t have a nickname field when setting up a profile for the first time, and have attempted to look through the code in WP Editor and don’t see any references to it. Help please!

    https://wordpress.org/plugins/theme-my-login/

Viewing 15 replies - 1 through 15 (of 26 total)
  • Same error here, only started happening after WP 4.4.1.

    It happens in different installs, with different themes, so it is related to the upgrade and how TMLI works with this newest version, regardless of theme.

    Please help.

    Any updates on this? I would really like to get this working again. Any suggestions are greatly appreciated!

    This plugin doesn’t work with latest WP version (4.4.1).

    Hmm. The Author says that it’s compatible. I was hoping to hear from Jeff Farthing to see if he had a chance to look into it yet, or needed more info.

    Marking my place. I’m having the same issue.

    max

    (@maximledoux)

    I’m getting this error, too. However, even though it displays as an error, any changes to profile are saved. So it’s not that bad. Still, it is confusing for my web site’s members. I considered using css to hide the error message, but that would also hide legitimate errors. I hope Mr. Farthing will release an update on this soon.

    Unfortunately, I’m not that lucky. The changes aren’t updated on my site. I, too, am hoping that Mr. Farthing lets us know if he’s found the issue soon. I appreciate all of you chiming in!

    max

    (@maximledoux)

    Until he does, you can do this work-around that I’m using.

    I have a custom profile-form.php in my theme folder that over-rides the profile-form.php that is in the plugin folder. I don’t have a field for nickname, since we don’t use it. So, I guess that’s why I’m seeing this error.

    So I took this bit of code from plugins/theme-my-login/templates/profile-form.php (line 50-53):

    <tr class="tml-nickname-wrap">
    			<th><label for="nickname"><?php _e( 'Nickname', 'theme-my-login' ); ?> <span class="description"><?php _e( '(required)', 'theme-my-login' ); ?></span></label></th>
    			<td><input type="text" name="nickname" id="nickname" value="<?php echo esc_attr( $profileuser->nickname ); ?>" class="regular-text" /></td>
    		</tr>

    And I put it somewhere in my custom profile-form.php (it doesn’t really matter where). Then I changed it like this:

    <tr style="display:none;" class="tml-nickname-wrap">
    			<th><label for="nickname"><?php _e( 'Nickname', 'theme-my-login' ); ?> <span class="description"><?php _e( '(required)', 'theme-my-login' ); ?></span></label></th>
    			<td><input type="text" name="nickname" id="nickname" value="<?php echo esc_attr( $profileuser->first_name ); ?>" class="regular-text" /></td>
    		</tr>

    See? I added style="display:none;" to the <tr> so that users won’t see any of this (that’s why it doesn’t matter where it goes). And I populated the field with $profileuser->first_name instead of $profileuser->nickname. You could do last_name, or something else. They’re not going to see it so it doesn’t matter.

    I hope that helps you. If so, just keep it in mind when Farthing does update the plugin to fix this problem. At that point we’ll both want to remove this from our custom profile-form.php.

    PS I also changed the table elements to divs.

    Max, you’re my hero. That worked like a charm! I had to change the variable to user_name instead of first_name because that’s all I require in my form, but after that, I was good to go! Thank you so much for this post!

    max

    (@maximledoux)

    Glad to help. There’s probably a better way to do it, but it works.

    Plugin Author Jeff Farthing

    (@jfarthing84)

    Just reading this today. I’ll look into it.

    Thanks Jeff! The workaround from above seems to be working for me but an official fix would probably help a lot of people out. Thank you for looking into it!

    Plugin Author Jeff Farthing

    (@jfarthing84)

    The nickname field is required – and it’s in TML’s profile template by default. If you don’t want it there, a simple workound is simply adding it as a hidden input.

    Strange, it didn’t start popping up until the latest WordPress update which is why I started this thread. Can you point me in the right directionas to how to add the nickname field as a hidden input?

    max

    (@maximledoux)

    I should have done that to start with. Not sure why I went with the more complicated CSS route. Oh, well.

    Replace what we did earlier with:

    <input type="hidden" name="nickname" id="nickname" value="<?php echo esc_attr( $profileuser->user_name ); ?>" class="regular-text" />

    (You can delete the css rule, too.)

Viewing 15 replies - 1 through 15 (of 26 total)
  • The topic ‘ERROR: Please Enter a Nickname’ is closed to new replies.