Download the PHP package ernestdefoe/parley without Composer

On this page you can find all versions of the php package ernestdefoe/parley. 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 parley

Parley

Chat for Flarum 2. See who is online and what they are reading, message anyone in a window that stays open while you browse the forum, and talk together in rooms.

Voice and video calls, and voice chat in rooms, are a separate paid add-on: Parley Calls (ernestdefoe/parley-calls), from $4 a month. Parley itself is free and MIT licensed.


Contents

  1. What you need
  2. Install
  3. Realtime (recommended)
  4. Settings
  5. Permissions
  6. Rooms
  7. What members can set
  8. Moderation
  9. Moving from ramon/chat
  10. Performance
  11. Troubleshooting
  12. Privacy
  13. For developers

1. What you need

Flarum 2.0 or later
PHP 8.3 or later, with the GD extension (for room logos)
flarum/realtime optional but recommended (section 3)
flarum/tags optional; needed to tie rooms to tags

2. Install

Run these as the web server's user (often www-data), not as root.

If the forum shows a 500 error straight after installing, run composer dump-autoload and reload PHP-FPM. That is Composer's class map catching up, not Parley.

The inbox lives at /parley. Flarum's own private-messages extension owns /messages, and two extensions claiming one address stop the whole forum loading, so Parley never uses it.

3. Realtime (recommended)

With flarum/realtime installed and its websocket server running, everything arrives the instant it happens: messages, typing dots, "seen", reactions, and changes to the online list.

Without it, Parley still works, more slowly:

With realtime Without
New messages in an open window instantly within 5 seconds
Unread counts, chat heads instantly within 15 seconds
Online list the moment someone arrives or leaves every 15 seconds
Typing dots yes no

Parley also watches the websocket itself. If realtime is installed but its connection is down, because the server stopped or is misconfigured, Parley falls back to the slower checks above until it reconnects. Nothing is lost while it is down.

Setting it up takes four steps. Parley Calls uses the same setup, so it is done once for both.

Run the websocket server

flarum/realtime ships a long-running server. Keep it running under a process manager, for example supervisor:

Point browsers and PHP at it

In config.php, the websocket block says where it listens and how each side reaches it. Browsers connect over HTTPS on port 443; PHP talks to it directly on the same machine:

⚠️ js-client-host is a hostname only: no port, no https://. forum.example.com:8080 there makes browsers try to connect to the wrong address and sit on "connecting" for ever, with no error.

Pass /app/ through to it

Browsers open wss://forum.example.com/app/<key>. Your web server must hand that path to the websocket server, upgrade headers included. For nginx:

If the forum sits behind Cloudflare, websockets pass through on 443; nothing else is needed.

Check it

Sign in, open the browser's console and run:

It should say connected. If it says connecting and never changes, go back to 3b and 3c.

4. Settings

Admin → Parley:

Setting Default
Rooms — Create and arrange rooms (section 6).
Minutes before Away 10 Someone who has not touched the page for this long shows as Away, until they come back.
Largest picture (MB) 8 The biggest picture a member can send in a conversation.

5. Permissions

Permission Default Means
Use Parley chat Members See the online list, message people, use rooms. Members without it see no Parley at all.
Hidden from the Parley online list nobody Members of these groups never appear in the online list, for example staff who would rather not be seen. Moderators still see them.
Review reported Parley messages Moderators See and handle reports (section 8), and remove messages in rooms.

Suspended members cannot use Parley while their suspension lasts. Members must have confirmed their email address before they can send anything.

6. Rooms

Rooms are made and arranged under Admin → Parley → Rooms.

A room's face is chosen in this order: its uploaded logo, then its emoji, then its tag's icon on the tag's colour, then #.

Members join a room by opening it, which means its messages arrive live and it counts unread for them. They can leave from the room's header. An @username in a room alerts that person, if they can see the room.

7. What members can set

8. Moderation

9. Moving from ramon/chat

Parley can bring your ramon/chat history across:

Run it before removing ramon/chat, while its tables still exist. Then:

Back up ramon/chat's tables first if you might want them again: migrate:reset drops them.

10. Performance

Parley is built so a busy forum does not pay for it in requests:

11. Troubleshooting

What you see Usually
No Parley on the page The member's group lacks Use Parley chat, or they are a guest. Guests are counted ("and 41 guests reading") but never shown the list.
Messages take a few seconds to appear Realtime is not installed, or its websocket is not connected (section 3).
No typing dots Same: typing needs a live websocket.
"…cannot receive messages" or "…only accepts messages from people they follow" That member's own choices (section 7).
A room is missing for some members It is tied to a tag they cannot see, or it is archived.
A room logo looks wrong in dark mode Upload a Dark mode logo for that room.
Forum shows a 500 straight after installing composer dump-autoload, then reload PHP-FPM (section 2).

12. Privacy

13. For developers

tools/rooms-e2e.mjs drives real browsers against a local forum to test rooms and the live online list; the file explains how to run it.

Parley leaves room for other extensions to build on it; Parley Calls is built entirely this way:

Support

Licence

MIT. See LICENSE.


All versions of parley with dependencies

PHP Build Version
Package Version
Requires php Version ^8.3
flarum/core Version ^2.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 ernestdefoe/parley contains the following files

Loading the files please wait ...