Support » Plugin: Log in with Google » Oauth2 parameters

  • Hello!

    Please, help-me with this question.

    How can i change the param “approval_prompt=auto” to “prompt=select_account”?

    I would like to know what file and line to edit.

    Best regards,
    Eric

Viewing 3 replies - 1 through 3 (of 3 total)
  • Hi,

    You can refer this line where client object is being made. However; currently it seems plugin is not passing any arguments to client constructor, so if you want to modify plugin code, you can pass an array like

    $client = new \Google_Client( array( 'prompt' => 'select_account' ) );

    Let me know if this works for you.

    Best Regards,
    Ankit G.

    Version 1.0.11, to be released shortly, will have a filter for modifying client arguments via a plugin or a theme’s functions.php:

    
    add_filter( 'login_with_google/client_arguments', function( $args ) {
        return array(
            'prompt' => 'select_account',
        );
    } );
    
    • This reply was modified 4 months, 2 weeks ago by Paul Clark.

    Hi Eric,

    Version 1.0.11 is release. Can you please try the solution suggested by Paul in above message?

    Best Regards,
    Ankit G.

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.