[wp-hackers] Users for each blog in Multi-Site?

Mike Walsh mpwalsh8 at gmail.com
Thu May 10 12:36:08 UTC 2012

The things I ended up using for solution were:

   1. get_users(array('blogid' => get_current_blog_id(), 'fields' => 'ID'))
   which returned a clean array of user ids.
   2. $wpdb->prefix
   3. $wpdb->base_prefix

Between the combination of these three I was able to get my plugin to work
correctly with both standard WordPress and Multi-Site, thanks for the
pointers to the multi-site functions and explanation of the relevant meta
data, both got me going in the right direction.


On Wed, May 9, 2012 at 6:43 PM, Brian Layman <wp-hackers at thecodecave.com>wrote:

> Yes, I believe so.
> Also note that the wp_ in the meta key isn't always wp_  Instead it is the
> table prefix as defined in wp-config.
> Brian Layman
> On 5/9/2012 2:18 PM, Mike Walsh wrote:
>> This is exactly what I was looking for, thank you!
>> Will the primary blog also be present in the meta table as a
>> wp_XX_capabilities entry?
>>  ______________________________**_________________
> wp-hackers mailing list
> wp-hackers at lists.automattic.**com <wp-hackers at lists.automattic.com>
> http://lists.automattic.com/**mailman/listinfo/wp-hackers<http://lists.automattic.com/mailman/listinfo/wp-hackers>

Mike Walsh - mpwalsh8 at gmail.com

More information about the wp-hackers mailing list