Viewing 6 replies - 1 through 6 (of 6 total)
  • just to hijack, wp-useronline is also using AJAX

    Download:
    https://www.lesterchan.net/others/downloads.php?id=14
    Demo:
    https://www.lesterchan.net/wordpress/ (Look At The Sidebar)
    https://www.lesterchan.net/wordpress/useronline/ (Detailed Page)

    Instructions:
    In the readme.html (included in the zip), read the Installation Tab followed by the Usage Tab

    Thread Starter neennoelle

    (@neennoelle)

    I think these are two different plugins?? One is useronline and the other is Who’s Online.

    For Who’s Online:
    “This plugin will show all users currently online, followed by all offline users in italics. You can click on a user’s name to view all posts by that user, and if you hover the mouse over a user’s name it will show you how long ago they were online. You need javascript enabled for the list to update without refreshing the page.”

    yeap it is different

    Thread Starter neennoelle

    (@neennoelle)

    Anyone else?

    Here are the instructions but it’s cryptic to me.

    “…activate the plugin and call tms_online_users(); where ever you want the currently online users displayed”

    What code do I put and where in the sidebar.php do I put it?

    Again this is for Plugin: AJAXed Who’s Online 0.61

    https://www.babatatas.com/?author=4

    Thread Starter neennoelle

    (@neennoelle)

    BUMP

    Just trying once more to see if anyone has had luck with this.

    Finally got AJAXed Who’s Online 0.61 to work through trial and error. Had to change the way the date was called as well as the format of the lastping record in the sql database. It does take a while to list all offline names if you have many members as it calculates time and links all posts for each member before display.

    What I want to do now, and I certainly could use a little help on this, is to show those currently online and “only” those who were on in the past 24 hours for all pages “except” the profile/member page. On the profile/member page I want to show everyone both online and offline.

    I have the code to do this working, but since plugin online_users.php is called from the sidebar (Andreas04 & 09), I am finding IF (is_page(’80’)) doesn’t work. My Profile/Member page is ?page_id=80. This is the code and it does work if I plug in the values:

    if (is_page (’80’)) {
    $query_offline = “SELECT user_id FROM tms_online_users WHERE lastping<FROM_UNIXTIME(‘”.$datetime[‘0’].”‘) ORDER BY lastping DESC”;

    } else {

    $query_offline = “SELECT user_id FROM tms_online_users WHERE lastping<FROM_UNIXTIME(‘”.$datetime[‘0’].”‘) && lastping>FROM_UNIXTIME(‘”.($datetime[‘0’] -86380).”‘) ORDER BY lastping DESC”;
    }

    It looks like is_page is not available when the plugin is called. I can force it to execute either one or the other by plugging the value but then one or the other always executes.

    Would appreciate it if someone could offer a suggestion or tell me why the if stmt doesn’t work.

Viewing 6 replies - 1 through 6 (of 6 total)
  • The topic ‘AJAXe’d Who’s Online’ is closed to new replies.