Adding Custom Pages to Who's Online

Discussion in 'vBulletin Discussions' started by ArnyVee, Sep 20, 2009.

  1. ArnyVee

    ArnyVee Regular Member

    Joined:
    May 25, 2009
    Messages:
    1,264
    Likes Received:
    39
    Guys and gals,

    I read this article over on vB.org ([HowTo] Add Custom Pages to WOL - vBulletin.org Forum) about adding my custom page(s) to the Who's Online so that they don't show as "unknown location".

    After reading the article and making the suggested adjustments on two new plugins, I get a white page with an error code after refreshing the "who's online" page. The error shows as this....

    Code:
    Error 2 (net::ERR_FAILED): Unknown error.
    ....any suggestions on what I could/should do to fix this?
     
  2. Wayne Luke

    Wayne Luke Regular Member

    Joined:
    Apr 2, 2009
    Messages:
    991
    Likes Received:
    276
    What does your code look like?
     
  3. ArnyVee

    ArnyVee Regular Member

    Joined:
    May 25, 2009
    Messages:
    1,264
    Likes Received:
    39
    Wayne, I'm using the plugin codes that Lynne posted on post #2 here: Who's Online: Unknown Location

    online_location_process

    Code:
    switch ($filename)
    {
    case 'mkattractions.php':
    $userinfo['activity'] = 'mkattractions';
    break;
    // add more cases here if you have more than one custom page. no need for multiple plugins. one plugin can handle all.
    }
    online_location_unknown

    Code:
    switch ($userinfo['activity'])
    {
    case 'mypage':
    $userinfo['where'] = '<a href="mkattractions.php?'.$vbulletin->session->vars[sessionurl].'">Magic Kingdom Attractions Page</a>';
    $userinfo['action'] = "Viewing MK Attractions Page";
    $handled = true;
    break;
    // add more cases here if you have more than one custom page. no need for multiple plugins. one plugin can handle all.
    }
     
  4. Wayne Luke

    Wayne Luke Regular Member

    Joined:
    Apr 2, 2009
    Messages:
    991
    Likes Received:
    276
    Change:
    case 'mypage':

    To:
    case 'mkattractions':

    I can't see any other issues with it though.
     
    2 people like this.
  5. ArnyVee

    ArnyVee Regular Member

    Joined:
    May 25, 2009
    Messages:
    1,264
    Likes Received:
    39
    :doh:

    LOL....thank you so much Wayne! :D
     
  6. Chani

    Chani Grand Master

    Joined:
    Sep 1, 2009
    Messages:
    884
    Likes Received:
    54
    First Name:
    Chani
    Don'cha just love these moments? :doh: I have them all the time. :o
     
  7. ArnyVee

    ArnyVee Regular Member

    Joined:
    May 25, 2009
    Messages:
    1,264
    Likes Received:
    39
    LOL....yup, these are special moments. :)
     

Share This Page