WordPress.org

Ready to get started?Download WordPress

Forums

Comment Guestbook
[resolved] Change email, name and logged in to different languange (3 posts)

  1. Tasha
    Member
    Posted 10 months ago #

    Hi, thank you for this great plugin. All works fine except for one thing. I need to change the language of the fields. I managed to change just about all the fields I need to except the following:

    Name:
    Email:
    Loggged in as:

    I used the following for logged in as:

    array(
             'logged_in_as' => '<p class="logged-in-as">' . sprintf( __( 'Ingeteken as <a href="%1$s">%2$s</a>. <a href="%3$s" title="Log out of this account">Wil jy uitteken?</a>' ), admin_url( 'profile.php' ), $user_identity, wp_logout_url( apply_filters( 'the_permalink', get_permalink( ) ) ) ) . '</p>'
    );

    [Moderator Note: Please post code & markup between backticks or use the code button. Your posted code may now have been permanently damaged by the forum's parser.]

    It worked except it doesn't show the user's name. It shows the following:
    Ingeteken as . Wil jy uitteken?

    Any help would be much appreciated.

    Thanks
    Tash

    https://wordpress.org/plugins/comment-guestbook/

  2. Tasha
    Member
    Posted 9 months ago #

    I just reread my post and realised "Ingeteken as . Wil jy uitteken?" doesn't mean anything to anyone. In English it would be:

    Loggged in as . Do you want to sign out?

    In other words it doesn't show the username after logged in if I translate the code.

  3. mibuthu
    Member
    Plugin Author

    Posted 9 months ago #

    The global variable $user_identity seems not be available in this content, same problem in my test installation.
    But you can use wp_get_current_user()->display_name instead.

Reply

You must log in to post.

About this Plugin

About this Topic