Netgate Discussion Forum
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Search
    • Register
    • Login

    Show number of users who are currently online on CP page

    Scheduled Pinned Locked Moved Captive Portal
    2 Posts 2 Posters 1.2k Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • K
      khoapham
      last edited by

      How do I show number of users who are currently online on CP page ?

      Something likes this:

      "There are 105 other people online"

      1 Reply Last reply Reply Quote 0
      • GertjanG
        Gertjan
        last edited by

        Well, you nailed it.
        A couple of billion things are missing in pfSEnse - this one of them !
        So, the "function" or "Environmental variable" that's initialized with the current online users doesn't exist.
        You have to make it yourself  ;)

        So, go grab a kid from the street and ask him to write a couple of PHP lines.
        Note that he isn't gona think a lot. He will 'borrow' some code from the gadget named "Captive Portal Status" and count the number of lines that that gadget will show.
        He will insert (include) the code in the portal page script.

        Done  ;D

        You didn't say anything about the version of pfSEnse you use, so I presume 2.0.3.

        No "help me" PM's please. Use the forum, the community will thank you.
        Edit : and where are the logs ??

        1 Reply Last reply Reply Quote 0
        • First post
          Last post
        Copyright 2025 Rubicon Communications LLC (Netgate). All rights reserved.