The Support Forums will be in read-only mode for a scheduled maintenance window on 01 September 2016 14:00 UTC - 20:00 UTC. More information.

$blog_id is Wrong (3 posts)

  1. c0re
    Posted 4 years ago #

    Hey everyone!

    I've got a strange issue with a multisite-compatible template that I'm working on. Long story short, I'm trying to get timthumb to work on the template, and I've got code that works but is dependent on the subsite's ID.

    Normally this is not a problem as I can get it using the global $blog_id. For some reason, however, $blog_id always returns 1, even though I know the current site ID is 5.

    $current_site->id is also returning 1 for some reason.

    Otherwise, all my code seems to work just fine when I simply set $blog_id = 5;

    I should mention that I'm checking the ID in a functions.php function.

    Has anybody ever seen anything like this before? What could possibly be causing this to happen on a multisite install? I'm not really sure what else to do at this point.

  2. duncmorley
    Posted 4 years ago #

    I'm having the same issue, did you have any luck?

  3. Google timthumb and multisite, there are people who have made it work, but given the recent issues with timthumb, I doubt it'll be popular again for a while.

Topic Closed

This topic has been closed to new replies.

About this Topic


No tags yet.