Notifications
Clear all

wpForo 1.x.x [Solved] Where can I find and edit the file with login/register links on the JS popup

5 Posts
2 Users
1 Reactions
2,698 Views
Posts: 16
Topic starter
(@moenagy)
Eminent Member
Joined: 5 years ago

Hi , im aware that you can setup custom login/register links in the members admin of wpforo.

my question is , if Iā€™m not logged in and click on add new topic it comes with the JS pop up saying ā€œplease login or registerā€ where can I find that file and that code to edit manually.Ā 

Ā I have a POP UP login / register modal plugin , the login link for that modal is a CSS class and not an actual link .. so basically my question is , how can I add that CSS class to the login link of ONLY the Js pop up of wpforo, or just tell me where that file is please and ill code it myself.

4 Replies
Posts: 16
Topic starter
(@moenagy)
Eminent Member
Joined: 5 years ago

this image to give you a better understanding ,
I made a minor change in Chrome inspeact element to <span class="lrm-login">Login</span> ... and it it is able to load the login window I want.Ā  Where is that file, can't find it anywhere at all !! I'm only able to find the CSS related to the message box, I need to edit the box it self, not the CSS !!

please don't tell me there is no way to do that, then I can't use this software !Ā 

Sofy
Posts: 4772
 Sofy
Admin
(@sofy)
Support Team
Joined: 7 years ago

Hi @moenagy,

Please follow the steps:

1. Install the Simple Custom CSS and JS plugin: https://wordpress.org/plugins/custom-css-js/

2.Ā  Add the following JS code via the pluginĀ 

jQuery(document).ready(function(){
jQuery('#wpf-msg-box a[href$="?wpforo=signin"]').replaceWith('<span class="lrm-login">Login</span>');
});

This works after the page loading.Ā 

Ā If you remove the #wpf-msg-boxĀ selector from the code above, it'll replace all login links (wpForo).Ā 

Another way is changing the add_footer_html() function in wp-content/plugins/wpforo/wpf-includes/class-template.php file.Ā 

The second one is not the update safe way.Ā 

Posts: 16
Topic starter
(@moenagy)
Eminent Member
Joined: 5 years ago

Iā€™ll try that as soon as I get back home, I shall do the same to the register link too with another JS code via that plugin to replace the register link?

Posts: 16
Topic starter
(@moenagy)
Eminent Member
Joined: 5 years ago

it sure works !!! thank you so much for the help šŸ™‚Ā