[wp-trac] [WordPress Trac] #12993: 'get_current_blog()' and/or 'current_blog_id()' function?

WordPress Trac wp-trac at lists.automattic.com
Tue May 4 15:52:26 UTC 2010


#12993: 'get_current_blog()' and/or 'current_blog_id()' function?
-----------------------------+----------------------------------------------
 Reporter:  martythornley    |       Owner:                       
     Type:  feature request  |      Status:  new                  
 Priority:  normal           |   Milestone:  Future Release       
Component:  Multisite        |     Version:  3.0                  
 Severity:  normal           |    Keywords:  current blog, blog id
-----------------------------+----------------------------------------------
Changes (by nacin):

  * milestone:  3.0 => Future Release


Comment:

 > People are currently having to call global variables to use $wpdb,
 $current_site and/or $blog_id. I feel all of these are messy and pretty
 generic variables to be using within theme or plugin files.

 Introducing a *fourth* way to determine blog ID isn't going to get more
 cleaner.

 The global $blog_id has existed for quite some time, even outside of MU in
 regular WP. So that's not going anywhere. Given WP's dependence on globals
 already, these should be relied on for the most part.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/12993#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list