Is there a function that returns the current blog ID number? that is, the blog prefix number?
Is there a function that returns the current blog ID number? that is, the blog prefix number?
$blog_id
It's not a function but a variable passed through the code.
Regards,
-drmike
I tried that. I think it's too early in the stream because I get
Undefined variable: blog_id
I'm putting the call in the main index.php page prior to the main wp-blog-header.php include. Maybe that's the problem.
Is there a way to call the variable prior to this include?
You're not forgetting the dollar sign, are you?
I can't do a search through the code on this computer. It's going to have to be tomorrow before I check this out.
What are you trying to do anyway?
Gotta call it as a global, first.
I was looking at the globals but I would thik it would be where you called it from.
Seems that I get an error if I try to use $blog_id with out
global $blog_id;
first.
function fubar() {
global $blog_id;
echo $blog_id;
}
That the very basics of it, but you get the idea.
Gotta make it available to the function if it needs it.
No different than wpdb, or others.