IRC-Documentation/doc/prefixing.md
2024-12-28 13:18:12 -08:00

921 B

⬅️ Back to index

Colon prefixing

In some commands (like PRIVMSG, TOPIC, USER, NOTICE, etc), the client needs to add a colon before the content (NOT after the command)

Your client shouldn't do this:

↗️ PRIVMSG foo this is a very cool message
🔀 nick!ident@host PRIVMSG foo :this

The server will only detect the first word

Your client shouldn't do this either:

↗️ PRIVMSG foo: this is a very cool message
↙️ :server 401 nick foo: :No such nick/channel

The server will think that the target (or whatever is before the content) ends with a colon.
For more info on error 401, see No such nick/channel

Here's what it should do:

↗️ PRIVMSG foo :this is a very cool message
🔀 nick!ident@host PRIVMSG foo :this is a very cool message

Your client should be able to parse the colon out.

<nick> this is a very cool message