[wp-trac] [WordPress Trac] #12258: Bug: Wrong blog title
WordPress Trac
wp-trac at lists.automattic.com
Wed Feb 17 09:39:26 UTC 2010
#12258: Bug: Wrong blog title
-----------------------------------------+----------------------------------
Reporter: _DorsVenabili | Owner:
Type: defect (bug) | Status: closed
Priority: high | Milestone: 2.9.3
Component: Themes | Version:
Severity: normal | Resolution: fixed
Keywords: theme custom header kubrick |
-----------------------------------------+----------------------------------
Comment(by _DorsVenabili):
I'm sory, my mistake, the right solution is:
<?php global blog_id; ?>
<h1><a href="<?php echo get_option('home'); ?>/"><?php echo
blog_name($blog_id); ?></a></h1>
And we add the next function in functions.php
function blog_name($blogid){
global $wpdb;
$blogname = $wpdb->get_var("SELECT meta_value FROM
wp_bp_user_blogs_blogmeta WHERE blog_id='".$blogid."' AND
meta_key='name'");
return $blogname;
}
--
Ticket URL: <http://core.trac.wordpress.org/ticket/12258#comment:2>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software
More information about the wp-trac
mailing list