Double Login in WP since Update

Ezrael
User ww
User ww
Posts: 25
Joined: Wed Nov 15, 2023 9:11 pm

Double Login in WP since Update

Post by Ezrael »

I don't know why but since the update to the current WP Version and your update, User have to login twice.

As soon as I deactivate your plugin, everything works like it should. Idk if its a cookie related issue or something else.
Ezrael
User ww
User ww
Posts: 25
Joined: Wed Nov 15, 2023 9:11 pm

Re: Double Login in WP since Update

Post by Ezrael »

Forgot to mention im speaking form the Wordpress login. PHPBB Login works without issues.

As soon as users use the WP login, after hitting login, the page refreshes and they aren't login. After repeating the login, they are login.

If I deactivate your plugin, WP Login works without issues.
Ezrael
User ww
User ww
Posts: 25
Joined: Wed Nov 15, 2023 9:11 pm

Re: Double Login in WP since Update

Post by Ezrael »

The only thing I know I also did before the update, I changed the side URL.

Before I use one subdomain for WP (https://photography.surferparadise.de) and another one for phpbb (https://forum.surferparadise.de). The phpBB Cookie-Setting was set to ".surferparadise.de"

I changed the WP Url to "surferparadise.de" (The Main domain) and the forum Url is still the subdomain mentioned above.

Overall_Footer is set to:

Code: Select all

<!-- IF not S_IS_BOT -->
<script type="text/javascript">
// START MANDATORY CHANGES
var w3allAllowDomain = '*'; // MANDATORY! // Set/Change this value with your WordPress URL (example: https://axew3.com)
var wordpress_url_page_forum = 'https://surferparadise.de/forum'; // MANDATORY! // (DO NOT ADD/INCLUDE final slash here) Url that point to your iframed wordpress forum page
var w3all_custom_wp_w3fancyurl = 'w3'; // MANDATORY! If you changed the default w3 to have 'fancy URL' query string into the related WP plugin admin option, then change this value to match the same as it is the fancy URL setting
// END MANDATORY CHANGES
Is it possible, that the change of the domain is causing the error?
User avatar
axew3
w3all User
w3all User
Posts: 2716
Joined: Fri Jan 22, 2016 5:15 pm
Location: Italy
Contact:

Re: Double Login in WP since Update

Post by axew3 »

Hello! The template integration code do not interfere any way with wordpress in this case, also because you are not into page-forum. And the cookie setting seem ok.

The unique thing changed about and into the default wordpress it works fine anyway, is
/wp-content/plugins/wp-w3all-phpbb-integration/class.wp.w3all-phpbb.php

line 712

Code: Select all

       if ( !defined( 'WP_ADMIN' ) ) // or throw Fatal error: Uncaught TypeError: call_user_func_array(): Argument #1 ($callback) must be a valid callback, function "wp_w3all_phpbb_login" not found or invalid function name ...
       {
        //do_action( 'wp_login', $user->user_login, $user );
       }
line
//do_action( 'wp_login', $user->user_login, $user );
was
do_action( 'wp_login', $user->user_login, $user );
but since you say it happen on default wp-login (so WP_ADMIN should be defined) it should not be the problem (but you can try).
User avatar
axew3
w3all User
w3all User
Posts: 2716
Joined: Fri Jan 22, 2016 5:15 pm
Location: Italy
Contact:

Re: Double Login in WP since Update

Post by axew3 »

....but i looked up https://photography.surferparadise.de/ and i see the wp-admin for an user is not accessible, so you not explained exactly the problem and the login happen into frontend? So the fix can be the above, OR you can also try to
change also this into file class.wp.w3all-phpbb.php
that should fix the issue:

lines 1035

Code: Select all

   if ( !defined( 'WP_ADMIN' ) && class_exists( 'UM' ) ){
    header("Refresh:0"); exit;
   }
change into

Code: Select all

 if ( !defined( 'WP_ADMIN' ) ){
    header("Refresh:0"); exit;
   }
Both (choose one or the other) should fix your issue: it seem the problem is that the user is logged in, but result to benot, until you do not move to another page or refresh the page, isn't it?
Post Reply