We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 8770
    • 21 Posts
    Hello,

    I’d like to have a box on my home page that sifts through the "Visitors now browsing" and displays all the .EDU sites now browsing. I’m not really asking how to do it (although that would be nice!) but rather where I would start when building something like that. I’d like to make it ajaxy, so it display’s in real-time, unless it’s too much of a load on the server.

    Thanks in advance,
    Mike
      • 22815
      • 1,097 Posts
      You’d start by figuring out where this data is stored, and how you could pull from that the information you want in an SQL query.

      Then you’d write a snippet that queried the database table and spat out whatever .edu domains it found.

      Reloading such a query multiple times while a document is open (regardless of whether the user wants to have it update) *is* too much of a load on the server, although a button that reloaded just that part of the page would be less of a load than the user just hitting refresh.
        No, I don't know what OpenGeek's saying half the time either.
        MODx Documentation: The Wiki | My Wiki contributions | Main MODx Documentation
        Forum: Where to post threads about add-ons | Forum Rules
        Like MODx? donate (and/or share your resources)
        Like me? See my Amazon wishlist
        MODx "Most Promising CMS" - so appropriate!
        • 8770
        • 21 Posts
        well, i noticed that the data is stored in the manager’s "visitors now browsing" page. where is that data stored, in the DB or the logs? there’s a couple of ways I can go about doing this once I know where that data is coming from.

        Thanks
          • 22815
          • 1,097 Posts
          No, that data is *displayed* in the manager page. It *is* stored in the db, I just don’t know where. (It depends on the stats module you are using).
            No, I don't know what OpenGeek's saying half the time either.
            MODx Documentation: The Wiki | My Wiki contributions | Main MODx Documentation
            Forum: Where to post threads about add-ons | Forum Rules
            Like MODx? donate (and/or share your resources)
            Like me? See my Amazon wishlist
            MODx "Most Promising CMS" - so appropriate!