AI Assistant
Notifications
Clear all

[Closed] Login name on Forum Title line

15 Posts
4 Users
4 Reactions
1,577 Views
Posts: 21
Topic starter
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
(@ghutchnet)
Eminent Member
Joined: 4 years ago
[#19334]

Many other forums have the login name displayed near the top of the forum page.  On WPForu it would look good on the main forum title line.  It could have an option to enable/disable it in settings.  Also the text could be editable with a default of "Hello %s" or "Welcome back %s".  If a guest is using the forum it could be blank.

As it is, unless you check your profile it is difficult to see if/how you are logged into the forum.

Just an idea... 😉 

Gary

wpForo Version
1.9.9.1
WordPress Version
5.8.2

14 Replies
dimalifragis
Posts: 2600
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
(@dimalifragis)
Famed Member
Joined: 6 years ago

Not related to your question BUT there is an "index.php" in your url and that is WRONG (in your whole site).

Also the "Wordpress" part of your url is UN-NEEDED (in your whole site). Since you are just staring, you better fix those because after some months, if you make the changes, your indexing and rank will be lost.


3 Replies
(@ghutchnet)
Joined: 4 years ago

Eminent Member
Posts: 21
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@dimalifragis thanks. I am aware of the WordPress and index.php issue. I have not been able to overcome it because of the file structure I've had to live with when I built my WordPress site.  When I setup wpforu it uses the url I have listed to access my forum page. I don't understand why.


dimalifragis
(@dimalifragis)
Joined: 6 years ago

Famed Member
Posts: 2600
dimalifragis
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@ghutchnet The "index.php" is because you have it in your PERMALINKS Wordpress options.

WP-ADMIN-->Settings-->Permalink and use the permalink structure change there.


(@ghutchnet)
Joined: 4 years ago

Eminent Member
Posts: 21
dimalifragis
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@dimalifragis Thank you!  I have corrected the index.php problem.  The path problem still persists.  This site is built over an older site and I had to nest the new wordpress site inside the existing public_html folder.


Chris
Posts: 3610
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
(@chris)
Famed Member
Joined: 5 years ago

Hi @ghutchnet,

Posted by: @ghutchnet

Many other forums have the login name displayed near the top of the forum page.  On WPForu it would look good on the main forum title line.  It could have an option to enable/disable it in settings.

Can you provide screenshots.

Also, if you add wpForo Profile & Notification Widget, To show Users info on the sidebar.

 

Posted by: @ghutchnet

also the text could be editable with a default of "Hello %s" or "Welcome back %s".

You can edit every wpForo phrase from Dashboard > Forums > Phrases Page, 

 


3 Replies
(@ghutchnet)
Joined: 4 years ago

Eminent Member
Posts: 21
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@chris Thank you for the widget suggestion.  I have now applied that as you will see.  I would still prefer the option of showing the user's name, or nickname, in the forum body if possible.  I am attaching a screenshot I edited to show what I am suggesting.

 triumphforum

Chris
(@chris)
Joined: 5 years ago

Famed Member
Posts: 3610
Chris
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@ghutchnet,

I don't think that this option will be included in our to-do list, the reason is that wpForo Dev team is working on 2.0 version which is a very big update with huge work to do. 

However, you can reach this yourself by theme customization, if you have PHP and WordPress coding knowledge, or you can contact gVectors custom work team with sales[at]gvectors.com, for custom work by your needs.

Check the below Doc about wpForo Theme Customization:

https://wpforo.com/docs/root/forum-themes/theme-customization/


(@ghutchnet)
Joined: 4 years ago

Eminent Member
Posts: 21
Chris
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@chris I understand. Thank you for responding. I really appreciate that. I look forward to the next iteration. 🙂


Tutrix
Posts: 1519
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian
(@tutrix)
Noble Member
Joined: 6 years ago

Hi @ghutchnet

you can use this PHP code

<?php
if ( is_user_logged_in() ) {
$current_user = wp_get_current_user();
if ( ($current_user instanceof WP_User) ) {
echo ' </br>¡Hello ' . esc_html( $current_user->display_name . '!');
}
}
?>

and paste it into the forum.php at the desired position

wpforo > wpf-themes > classic > forum.php


5 Replies
(@ghutchnet)
Joined: 4 years ago

Eminent Member
Posts: 21
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@tutrix wow! Thank you. I will consider this avenue.  I will play with it soon.  😀


Tutrix
(@tutrix)
Joined: 6 years ago

Noble Member
Posts: 1519
Tutrix
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@ghutchnet 

Inspired by your question, I also added this to my forum, with an additional info for guests 😉 

   <div class="wpf-welcome"><?php if (is_user_logged_in()) {
    $current_user = wp_get_current_user();
    echo 'Hallo <span>' . esc_html($current_user->display_name) . '</span> willkommen im Forum!';
} else {
    // Save current page url for redirect after login (optional):
    global $wp;
    $redirect = home_url($wp->request);

    echo 'Willkommen im Tutrix Forum, du musst dich <a href="' . esc_url(wp_login_url($redirect)) . '">anmelden oder regisrieren</a> um Beitr&auml;ge verfassen zu k&ouml;nnen';
} ?>
   </div>

replace the german words with text in your language


(@ghutchnet)
Joined: 4 years ago

Eminent Member
Posts: 21
Tutrix
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@tutrix Very nice!  This goes into forum.php as well?


Tutrix
(@tutrix)
Joined: 6 years ago

Noble Member
Posts: 1519
Tutrix
Tutrix
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@ghutchnet 

yes, on top directly after

<?php
if( !$forum = WPF()->current_object['forum'] ) : ?>

(@ghutchnet)
Joined: 4 years ago

Eminent Member
Posts: 21
Tutrix
Tutrix
Translate
English
Spanish
French
German
Italian
Portuguese
Russian
Chinese
Japanese
Korean
Arabic
Hindi
Dutch
Polish
Turkish
Vietnamese
Thai
Swedish
Danish
Finnish
Norwegian
Czech
Hungarian
Romanian
Greek
Hebrew
Indonesian
Malay
Ukrainian
Bulgarian
Croatian
Slovak
Slovenian
Serbian
Lithuanian
Latvian
Estonian

@tutrix I made a few changes including the english translation. I also moved it to just before the first <h1>

 

<div class="wpf-welcome" style="padding-right: 1px; font-size: 13px;"><?php if (is_user_logged_in()) { // This adds Welcome user message :
$current_user = wp_get_current_user();
echo 'Welcome back, <span><strong>' . esc_html($current_user->display_name) . '</strong></span>!';
} else {
// Save current page url for redirect after login (optional):
global $wp;
$redirect = home_url($wp->request);

echo 'Welcome to the <span>' . esc_html(WPF()->general_options['title']) . '</span>,<br> you must<span> <a href="https://triumphclub.org/wordpress/community/?foro=signin">Login or Register</a> to post</span>';
} ?>
</div>

Share: