Download the PHP package ianm/online-guests without Composer

On this page you can find all versions of the php package ianm/online-guests. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package online-guests

Online Guests Widget

License Latest Stable Version Total Downloads

A Flarum extension that adds a forum widget showing how many guests (logged-out visitors) are currently browsing your forum.

Screenshot

image

How it works

The widget counts active guest sessions — that is, sessions that are not associated with a logged-in user. The count is determined by inspecting Flarum's session storage, so the supported methods depend on your configured session driver (see Supported session drivers below).

To avoid recalculating on every page load, the result is cached for a configurable period (default: 600 seconds / 10 minutes). The widget is built on top of Forum Widgets Core, which is installed automatically as a dependency and lets admins position, reorder, and toggle widgets from the dashboard.

Supported session drivers

Driver Supported Notes
file ✅ The Flarum default. Guest sessions are counted by scanning the session files on disk.
redis ✅ Requires fof/redis. Guest session IDs are tracked in a sorted set and counted in real time.
other ❌ Any other driver returns a count of 0. Sponsorship of additional drivers (e.g. database) is welcome.

Redis sessions

When you use fof/redis with the Redis session handler, this extension automatically registers a middleware that records the session ID of each guest request in a Redis sorted set, scored by request time. The widget then prunes entries older than the configured Online duration and counts what remains — no disk scanning required.

fof/redis is listed as a Composer suggest, so it is not installed by default. To enable Redis support, install and configure it separately:

Then enable Redis sessions in the FoF Redis extension settings. No further configuration is needed in this extension — it detects the active session handler automatically.

Settings & permissions

From the admin dashboard you can configure:

A View online guests permission controls which groups can see the widget. Only actors with this permission receive the guest count.

Installation

Install with composer:

This will also install Forum Widgets Core, which the widget relies on.

Updating

Links


All versions of online-guests with dependencies

PHP Build Version
Package Version
Requires flarum/core Version ^2.0.0
fof/forum-widgets-core Version ^2.0.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package ianm/online-guests contains the following files

Loading the files please wait ...