• jrytesting

    (@jrytesting)


    This might be interesting when having difficulties in login by Facebook (using WP social login).

    First I got Facebook error message: “The redirect_uri URL must be absolute”. I happened to read article “https://github.com/miled/wordpress-social-login/issues/44”. There is mentioned that “maybe that’s due to plugins_url(). if that’s the case you, then may redefine WORDPRESS_SOCIAL_LOGIN_PLUGIN_URL
    https://github.com/miled/wordpress-social-login/blob/master/wp-social-login.php#L86″.

    And yes, as I changed the line (in file wordpress-social-login/wp-social-login.php) (I added site_url to the front of plugin_dir)

    … define( ‘WORDPRESS_SOCIAL_LOGIN_PLUGIN_URL’, plugin_dir_url( __FILE__ ) );
    to
    … define( ‘WORDPRESS_SOCIAL_LOGIN_PLUGIN_URL’, site_url() . plugin_dir_url( __FILE__ )

    The error disappeared. I am not sure if this is a hosting service problem, the functions plugins_url() and plugin_dir_url() return
    /wp-content/plugins/

    I guess they should return the absolute path starting with https://mydomain….

    Then as that problem was solved, there was an another one. Facebokk returned error message “URL Blocked: This redirect failed because the redirect URI is not whitelisted in the app’s Client OAuth Settings. Make sure Client and Web OAuth Login are on and add all your app domains as Valid OAuth Redirect URIs.”

    That was solved by defining in Facebook account Settings -> Advanced -> Client OAuth Settings -> Client OAuth Login to YES, Web OAuth Login to YES, and adding there the url
    https://mydomainsomethin.xx/wp-content/plugins/wordpress-social-login/hybridauth/?hauth.done=Facebook

    Hopefully this helps someone with similar problems.

    https://www.ads-software.com/plugins/wordpress-social-login/

Viewing 1 replies (of 1 total)
  • hi, jrytesting

    Thank you very much.
    Your suggestion does help.

    I needed the returned URL, and finally I found you.
    Thanks a again.

Viewing 1 replies (of 1 total)
  • The topic ‘The redirect_uri URL must be absolute, OAuth Settings, Facebook’ is closed to new replies.