Skip Navigation

This thread is resolved. Here is a description of the problem and solution.

Problem:
You are trying to translate a login page that uses a custom slug instead of the default wp-login.php. While the English version of the login page works correctly, the translated version under /es/[custom-slug] results in a 404 error. This issue arises when using the Defender Pro plugin to rename the login slug, which suggests that the problem is not with BuddyBoss itself but with how the login behavior is modified by the security plugin.
Solution:
First, verify if Defender Pro supports translating the custom login slug, as the necessary options for translation might not be present. We recommend installing BuddyPress and the security plugin in an isolated sandbox environment to explore possible code workarounds. You can access a sandbox here: sandbox environment. Additionally, consider contacting the authors of Defender Pro and encourage them to join our Go Global program, where we can assist them in making the necessary code adjustments.

If this solution does not resolve your issue or seems outdated, please check for related known issues at https://wpml.org/known-issues/, verify the version of the permanent fix, and confirm that you have installed the latest versions of themes and plugins. We highly recommend opening a new support ticket if the problem persists. You can do so here: WPML support forum.

This is the technical support forum for WPML - the multilingual WordPress plugin.

Everyone can read, but only WPML clients can post here. WPML team is replying on the forum 6 days per week, 22 hours per day.

This topic contains 0 replies, has 0 voices.

Last updated by kyleM-11 1 week, 3 days ago.

Assisted by: Marcel.

Author Posts
March 30, 2025 at 2:51 am #16875979

kyleM-11

Background of the issue:
I am trying to translate the login page, which is under a custom slug, not wp-login.php. The English login page works fine, but I encounter a 404 error under /es/[custom-slug]. This is a BuddyBoss login page.

Symptoms:
I get a 404 error when trying to access the translated login page under /es/[custom-slug].

Questions:
How can I translate the login page with a custom slug?
Why am I getting a 404 error on the translated login page?

April 1, 2025 at 5:03 pm #16884095

Marcel
WPML Supporter since 02/2019

Languages: English (English ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

Hi,

do you have a staging environment to run some tests? I would eventually also need to request temporary access (WP-Admin and FTP) to your site
– preferably to a test site where the problem has been replicated if possible –
in order to be of better help and check if some configurations might need to be changed

Your next answer will be private which means only you and I have access to it.

❌ Please backup your database and website ❌

✙ I would additionally need your permission to de-activate and re-activate Plugins and the Theme, and to change configurations on the site. This is also a reason the backup is really important.

✙ Please add the Links to the […] Edit Screen, the Page/Post where you insert the […] and the corresponding Front End Page/Screen

Best Regards,
Marcel

April 4, 2025 at 4:05 pm #16898495

Marcel
WPML Supporter since 02/2019

Languages: English (English ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

Hi,

I'm encountering the following error when I try to log in:
ERROR: User can't find

Could you please take a look and let me know?

Thanks!

Best regards,
Marcel

April 7, 2025 at 4:51 pm #16905515

Marcel
WPML Supporter since 02/2019

Languages: English (English ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

Hi,

thanks! As far as I see the menu entry is not translated, therefore the 404:

There is no Spanish menu created: hidden link, see https://wpml.org/documentation/getting-started-guide/translating-menus/.

Does the translation of the menu solve it for you?

Best Regards,
Marcel

April 7, 2025 at 5:51 pm #16905605

kyleM-11

No - that's the logged out mobile version of the menu.
In any case, I need domain.com/access to be translated.
The Login button comes from the theme - Buddyboss.
And the Login page is also created by the theme - Buddyboss.
Have you not had people using Buddyboss have this issue?

April 8, 2025 at 2:55 pm #16910123

Marcel
WPML Supporter since 02/2019

Languages: English (English ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

Hi,

there are currently no related issues reported for BuddyBoss. You can see them here: https://wpml.org/plugin/buddyboss-platform/.

The /access slug is not a default setting in BuddyBoss, as shown here: BuddyBoss Theme Documentation. Could you clarify where and how you defined this slug?

By default, BuddyBoss uses the standard wp-login.php for login. If you've changed this, we need to identify where the change was made to ensure the function exists. Modifying the default login slug may require a custom solution, as explained here: Customizing the Login URL for Different Languages in BuddyBoss.

Best Regards,
Marcel

April 9, 2025 at 12:59 am #16911184

kyleM-11

Thanks! Actually it looks like their issue is somewhat reverse from ours.

We have a plugin that obfuscates the /wp-login slug and simply replaces it with /access.

So the Login button here: hidden link

Leads to hidden link

But the login button in the spanish version: hidden link

Leads to: hidden link

Which is a 404 - isn't a page.

We want the Spanish version Login button to lead to /access

And we want to translate that page - and so when people go from hidden link to the login page, they get the Spanish version of that login page (hidden link)

April 9, 2025 at 4:20 pm #16915041

Marcel
WPML Supporter since 02/2019

Languages: English (English ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

Hi

thanks for the clarification. So, you're renaming the login slug using Defender Pro. The key point here is that without Defender Pro—when using the default wp-login.php—everything works as expected, and it even includes the language switcher on the login page (which is not viewable when using Defender Pro).

This suggests the issue isn't with BuddyBoss itself, but rather with how the login behavior is being modified by the security plugin.

The main question now is whether Defender Pro supports translating the custom login slug. At the moment, I don’t see any relevant string in the options table that would allow for this kind of translation.

Please install BuddyPress and the security plugin on this isolated sandbox environment so we might can see if a suitable code workaround is possible:
hidden link

However, I recommend reaching out to the Defender Pro authors and encouraging them to apply for our Go Global program. Through this program, we can help them find a suitable code change to address the issue.

Best regards,
Marcel

April 9, 2025 at 4:36 pm #16915063

kyleM-11

Thank you for troubleshooting the source of the issue.

I see that essentially the Spanish version will always prepend /es/ to the slug.

Without the custom slug via Defender - does WPML essentially create a second wp-login.php page? How is it handling the translation?

April 9, 2025 at 4:50 pm #16915087

Marcel
WPML Supporter since 02/2019

Languages: English (English ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

No, technically the login page isn't a regular WordPress page, so it's not "translated" in the same way as posts, pages, or custom post types. Instead, WPML handles language switching through internal redirection and by setting the appropriate locale.

WordPress uses a single wp-login.php file for all languages. Since it's not part of the WordPress page system, it can't be duplicated or translated per language. WPML ensures the login form appears in the correct language by loading the appropriate translation files—either from WordPress core or from themes and plugins—based on the active locale.

The regular lang switcher is even part of the WP core and not handled by WPML: https://make.wordpress.org/core/2021/12/20/introducing-new-language-switcher-on-the-login-screen-in-wp-5-9/.

Best Regards,
Marcel

April 14, 2025 at 11:39 pm #16931368

kyleM-11

OK, thanks. How can I then force that login url to be/access and not /es/access? Should I set a forwarder, or is there somewhere I can set that 'translation' string? I can't find it when filtering under all strings, either with login or access.

April 15, 2025 at 8:09 am #16932327

Marcel
WPML Supporter since 02/2019

Languages: English (English ) German (Deutsch )

Timezone: Europe/Madrid (GMT+02:00)

Hi,

It looks like the security plugin isn’t using proper getText() functions, which means its strings can’t be translated unless they already appear in the translation table.

A forwarder rule could be a potential workaround, or you might need to explore a custom coding solution.

Best regards,
Marcel

April 16, 2025 at 2:46 am #16936479

kyleM-11

Thank you, we've switched from the directory option to parameters and has solved this issue