WordPress.org

Ready to get started?Download WordPress

Forums

[Plugin: OpenID] sharing openID tables across blogs? (5 posts)

  1. tgiokdi
    Member
    Posted 5 years ago #

    Is it possible to share the openID information across different blogs that are already sharing the user tables? I found reference to 'CUSTOM_OPENID_IDENTITY_TABLE' but I'm not clear how to properly use that in the wp-config.php file.

    Thanks!

  2. Will Norris
    Member
    Posted 5 years ago #

    Did you find the reference by looking in the code or at the DiSo Wiki:
    http://wiki.diso-project.org/wordpress-openid-api#HiddenOptions
    If you haven't seen this wiki page, take a look.

    If you're already sharing the user table, then you have some special definitions in your wp-config.php similar to what is instructured at:
    http://codex.wordpress.org/Editing_wp-config.php#Custom_User_and_Usermeta_Tables

    Just do the same thing, using the key 'CUSTOM_OPENID_IDENTITY_TABLE', and whatever table name you want to use. The default table name is $wpdb->prefix . 'openid_identites'.

  3. tgiokdi
    Member
    Posted 5 years ago #

    that's exactly what I've found, but I'm not sure how to translate the phrase "$wpdb->prefix . 'openid_identites'. " into what I'm using for the other shares.

    is that supposed to say "prefix-openid_identities"? what's the table name that's actually being shared? I don't think I've ever actually run into that syntax before :(

  4. Will Norris
    Member
    Posted 5 years ago #

    "$wpdb->prefix" is the same things as "$table_prefix" in your wp-config.php file. This means that, by default, the name of the table will be whatever your table prefix is, combined with the string "openid_identities". If you table prefix is "wp_", then the actual table name will be "wp_openid_identities".

    What do you have set for your CUSTOM_USER_TABLE ?

  5. tgiokdi
    Member
    Posted 5 years ago #

    ah, I see now. what was confusing me was the period that was in the middle of the prefix and the table name. So, if I wanted to share the default wordpress prefix's table, I used :


    '
    define('CUSTOM_OPENID_IDENTITY_TABLE', 'wp_openid_identities');
    '

    that worked out perfectly, thanks for helping a dense guy out wnorris ;)

    I've combined this with the method of sharing the user tables, so now registered users can log in with their openID on all my sites, yay!

Topic Closed

This topic has been closed to new replies.

About this Topic

Tags