Title: Custom login problem
Last modified: September 1, 2016

---

# Custom login problem

 *  Resolved [tonito9](https://wordpress.org/support/users/tonito9/)
 * (@tonito9)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/custom-login-problem/)
 * Hi, I have a problem using this plugin along with my custom login. When I deactivate
   it works just fine, and i think it have something to do with cookies.
 * With plugin activated content of wordpress cookie is just ‘+’.
 * [https://wordpress.org/plugins/wp-w3all-phpbb-integration/](https://wordpress.org/plugins/wp-w3all-phpbb-integration/)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  Plugin Author [axew3](https://wordpress.org/support/users/axewww/)
 * (@axewww)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/custom-login-problem/#post-7507478)
 * Depend how your custom login is coded, wp_w3all since lastest release try to 
   detect externals logins, and try to bypass those like Ultimate Member or others.
 * If you have not problems with wp_w3all logins, and problems are coming out only
   on your login, can be fixed but, you should see where something go wrong. What
   you have in this login that you need, recaptcha?
 *  Thread Starter [tonito9](https://wordpress.org/support/users/tonito9/)
 * (@tonito9)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/custom-login-problem/#post-7507487)
 * Hi, thank you for response.
 *     ```
       function custom_login() {
       	if($_POST['log_submit']) {
       		$creds = array();
       		$creds['user_login'] = $_POST['log_username'];
       		$creds['user_password'] = $_POST['log_pass'];
       		$creds['remember'] = true;
       		$user = wp_signon( $creds, false );
       		wp_set_current_user($user);
       		if ( is_wp_error($user) )
       			echo $user->get_error_message();
       	}
   
       }
       // run it before the headers and cookies are sent
       add_action( 'after_setup_theme', 'custom_login' );
       ```
   
 * i am using this, and have simple login form, only username, password, remember
   me and submit button.
 * I wan’t to make it so that users only register and login through wordpress.
 * After login there is like 16 cookies, all of phpbb cookies content are ‘deleted’
   and wordpress cookies content are ‘+’.
 * Is there a way to implement custom login, have you done it already?
 *  Plugin Author [axew3](https://wordpress.org/support/users/axewww/)
 * (@axewww)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/custom-login-problem/#post-7507680)
 * Hello, summer has start here, so sorry for the delay … 2 month of sunshine you
   know 🙂
    wp_w3all grab credentials before any action hook: on next can be set
   as option to be activated or not.
 * Look that wp_w3all, when an user login on WP side, send related phpBB cookies
   browser. When an user login on phpBB side and come into WP side, than wp_w3all
   detect and validate phpBB cookie, and login the user into WP.
 * Now, if you want your custom login code work with wp_w3all, you should take care
   that your code, send also required phpBB cookies onlogin OR, wp_w3all, will logout
   you, as can’t find out a valid phpBB cookie to check against. Further more wp_w3all
   run hooks mainly on init, and not on after_setup_theme: so wp_w3all is executed
   before your code.
    And the latest addition, about external logins even before
   just grabbing the $_POST array (look _addons/ext\_plugins\_fixes.php_) that is
   included (if you would like to exclude) on file wp_w3all.php
 *     ```
       //// workaround for some plugin that substitute wp-login.php default login page
       //// ... but that DO NOT reset $_POST array (like some frontend ajax login widget plugin instead do)
   
        require_once( WPW3ALL_PLUGIN_DIR . 'addons/ext_plugins_fixes.php' );  // code, actions and functions
   
       //// END workaround for some plugin that substitute wp-login.php default login page
       ```
   
 * There are several, really many answer i could give you, hope this will help, 
   if not, just repost.
 *  Plugin Author [axew3](https://wordpress.org/support/users/axewww/)
 * (@axewww)
 * [9 years, 11 months ago](https://wordpress.org/support/topic/custom-login-problem/#post-7507771)
 * [solved]

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Custom login problem’ is closed to new replies.

 * ![](https://ps.w.org/wp-w3all-phpbb-integration/assets/icon-128x128.png?rev=3375511)
 * [WP w3all phpBB](https://wordpress.org/plugins/wp-w3all-phpbb-integration/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-w3all-phpbb-integration/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-w3all-phpbb-integration/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-w3all-phpbb-integration/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-w3all-phpbb-integration/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-w3all-phpbb-integration/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [axew3](https://wordpress.org/support/users/axewww/)
 * Last activity: [9 years, 11 months ago](https://wordpress.org/support/topic/custom-login-problem/#post-7507771)
 * Status: resolved