====== Text Files ======

Text files that are displayed to remote clients / users and some configuration type files are stored in the ''[[dir:text]]'' directory.

===== Contents =====

Text files with the following filename suffixes/extensions, may include Synchronet [[custom:atcodes|@-codes]] and [[custom:Ctrl-A Codes]] to customize the appearance and contents of the files for your BBS:

  * ''.asc''
  * ''.ans''
  * ''.mon''
  * ''.msg''
  * ''.seq''
  * ''.rip'' 
  * ''.utf8''

===== Display Files ======

^Filename / Page     ^Default Contents^Description^
|''[[answer.*]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/answer.msg|answer.msg]]|Login screen displayed to Terminal clients upon connection (all variants also supported)|
|''[[bullseye.asc]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/bullseye.asc|bullseye.asc]]|Bullseye! Bulletins Menu (see also ''bullseye.cfg'')|
|''[[sbbs.msg]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/sbbs.msg|sbbs.msg]]|Message regarding Synchronet features and usage displayed to new users (1st)|
|''[[system.msg]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/system.msg|system.msg]]|Message regarding your system displayed to new users (2nd)|
|''[[newuser.msg]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/newuser.msg|newuser.msg]]|Message displayed to user during new user sign-up (3rd)|
|''[[feedback.msg]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/feedback.msg|feedback.msg]]|Message displayed to user before requesting new user feedback letter (4th)|
|''[[welcome.msg]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/welcome.msg|welcome.msg]]|Optional welcome message e-mailed to new users (enabled in the [[module:newuser]] module)|
|''[[nonodes.txt]]''   |<none>|Optional message displayed before disconnection due to no [[server:terminal|Terminal Server]] nodes being available for login|

====== Logon Message Flow Chart ======

  ╔═══════════════╗
  ║ text/answer.* ║
  ╚═══════╤═══════╝
    ┌─────┴─────────────────┐ ┌─────┐ ╔═══════════════╗
    │ text/banner.* exists? ├─┤ Yes ├─╢ text/banner.* ║
    └─────┬─────────────────┘ └─────┘ ╚═══════════════╝
  ┌───────┴──────────────────────┐
  │ Login Prompt (exec/login.js) │
  └───────┬──────────────────────┘
    ┌─────┴─────┐ ┌─────┐ ╔═══════════════╗ ╔═════════════════╗
    │ New User? ├─┤ Yes ├─╢ text/sbbs.msg ╟─╢ text/system.msg ║
    └─────┬─────┘ └─────┘ ╚═══════════════╝ ╚════════╤════════╝
       ┌──┴─┐                               ╔════════╧═════════╗
       │ No │                               ║ text/newuser.msg ║
       └──┬─┘                               ╚════════╤═════════╝
          │                                ┌─────────┴──────────┐
          │                                │ Password Selection │
          │                                └─────────┬──────────┘
          │                               ┌──────────┴────────────┐
          │                               │ Default Configuration │
          │                               └──────────┬────────────┘
          │  ╔═══════════════════╗ ┌─────┐ ┌─────────┴──────────┐
          │  ║ text/feedback.msg ╟─┤ Yes ├─┤ Feedback Required? │
          │  ╚═════════╤═════════╝ └─────┘ └─────────┬──────────┘
          │    ┌───────┴───────┐                  ┌──┴─┐
          │    │ Send Feedback │                  │ No │
          │    └───────┬───────┘                  └──┬─┘
          │  ┌─────────┴──────────────────────────┐  │
          │  │ New User Module (exec/newuser.js)  ├──┘
          │  └─────────┬──────────────────────────┘
          │  ┌─────────┴─────────┐                   
          │  │ New User Event(s) │
          │  └─────────┬─────────┘
  ┌───────┴────────────┴─────────┐
  │ Logon Module (exec/logon.js) │
  └───────┬──────────────────────┘
          │  ╔═══════════════════════════════════╗
          └──╢ text/menu/logon<security-level>.* ║
             ╚═════════╤═════════════════════════╝
            ╔══════════╧════════╗
            ║ text/menu/logon.* ║
            ╚══════════╤════════╝
            ╔══════════╧═════════╗
            ║ text/menu/logon1.* ║
            ╚══════════╤═════════╝
                      ...
  
            ╔══════════╧══════════╗
            ║ text/menu/logon99.* ║
            ╚══════════╤══════════╝
            ╔══════════╧══════════╗
            ║ text/menu/random*.* ║
            ╚══════════╤══════════╝
              ┌────────┴───────┐
              │ Logon Event(s) │
              └────────────────┘

====== Area Info Files ======
If you want to have an information file displayed for sub-boards when using
the 'I' scanning command and 'IS' main menu command, create a file for the
sub-board in the ''data/subs'' directory using the internal code for that sub-board
as the base filename and any supported display/menu file suffix/extension. Example:

  data/subs/general.msg

If you want to create in information file for file directories to be displayed
with the 'ID' transfer section command, create a file for the directory in
the ''data/dirs'' directory using the internal code as the base filename and any
supported display/menu file suffix/extension. Example:

  data/dirs/games.ans

If you want to create a custom file listing header for a file directory, create
a file in the data/dirs directory using the internal code as the name and ''.hdr''
as the extension. Example:

  data/dirs/games.hdr

===== Filter Files =====

Trash can (''.can'') files allow the sysop to specify words (or any sequence of characters) that will be used to disallow users or their content.

Each line in a ''.can'' file may contain a comparison sequence. 

  * Blank lines and lines beginning with a semicolon are ignored
  * Comparisons are alphabetic letters are case-insensitive
  * Sequences //beginning// with an exclamation mark (''!'') negate the match logic for that sequence
  * Sequences //beginning// with an asterisk (''*'') match only if the characters following the ''*'' are found at the end of the comparison string
  * Sequences //ending// with an asterisk (''*'') or caret (''^'') match only if the characters preceding are found at the beginning of the comparison string
  * Sequences //ending// with a tilde (''~'') match only if the preceding characters are found anywhere within comparison string
  * All other sequences are "exact match" string comparisons
 
Examples:

  * ''sysop'' in the ''name.can'' file would mean users could not use the name "sysop".
  * ''sysop*'' would mean users could not use names beginning with the word "sysop", like "sysopa" or "sysops" etc.
  * ''sysop~'' would mean users could not use names that have the word "sysop" anywhere in them, like "imthesysop" or "mesysophere".

The following table lists the supported trash can / filter files, a description of their use, and optional response message (''.msg'') files that may be displayed to users that are filtered. 

^Filename / Page     ^Default Contents^Description^
|''[[email.can]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/email.can|email.can]]|Disallowed (source or destination) e-mail addresses (see also ''[[twitlist.cfg]]'')|
|''[[bademail.msg]]''||Optional message to display to users attempting to use a disallowed email address|
|''[[file.can]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/file.can|file.can]]|Disallowed filenames for upload|
|''[[badfile.msg]]''||Optional message to display to users who attempt to upload a disallowed filename|
|''[[host.can]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/host.can|host.can]]|Disallowed hostnames for connections|
|''[[badhost.msg]]''||Optional message to display to users who attempt to connect from a disallowed host|
|''[[ip.can]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/ip.can|ip.can]]|Disallowed IP addresses for connections|
|''[[badip.msg]]''||Optional message to display to users who attempt to connect from a disallowed IP address|
|''[[ip-silent.can]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/ip-silent.can|ip-silent.can]]|Silently-ignored IP addresses for connections|
|''[[name.can]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/name.can|name.can]]|Disallowed user alias|
|''[[badname.msg]]''||Optional message to display to users who attempt to use a disallowed alias|
|''[[phone.can]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/phone.can|phone.can]]|Disallowed phone numbers for new users|
|''[[badphone.msg]]''||Optional message to display to users who attempt to use a disallowed phone number|
|''[[subject.can]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/subject.can|subject.can]]|Disallowed message subjects|
|''[[badsubject.msg]]''||Optional message to display to users who attempt to use a disallowed subject in a posted message|

===== Miscellaneous =====
^Filename / Page     ^Default Contents^Description^
|''[[bullseye.cfg]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/bullseye.cfg|bullseye.cfg]]|Bullseye! Builletins Configuration (see also ''bullseye.asc'')|
|''[[example.sif]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/example.sif|example.sif]]|Example Synchronet Questionnaire file|
|''[[lbshell_bg.bin]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/lbshell_bg.bin|lbshell_bg.bin]]|Lightbar Command Shell background image (not text)|
|''[[ircmotd.txt]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/ircmotd.txt|ircmotd.txt]]|[[service:ircd|IRC Daemon]] "Message Of The Day"|
|''[[zipmsg.txt]]''   |[[https://gitlab.synchro.net/sbbs/sbbs/-/raw/master/text/zipmsg.txt|zipmsg.txt]]|ZIP message added to uploaded ''.zip'' files.|

===== QWK Files =====
If the following files existing in the system's ''[[dir:text]]/QWK'' directory, then they will be copied and packed into downloaded QWK packets (''.qwk'' files):

^ Filename ^ Description ^
| ''HELLO''    | Displayed when the QWK packet is opened |
| ''BBSNEWS''  | Latest news article (about the BBS) to display to the user |
| ''BLT-x.y''  | Bulletins (where x and y are decimal numbers) |
| ''GOODBYE''  | Displayed when the QWK packet is closed |

**Note:**\\
QWK packets created for QWK network nodes will not include these files.

**Note:**\\
Not all QWK offline mail readers will display these files when included in opened QWK packets.

===== Menu Files =====

Menu files displayed to the remote terminal client / user are stored in the ''[[dir:text]]/menu'' directory hierarchy.

Menu files may have one of the following file suffixes / extensions:

^Extension   ^Description^
|''.msg''        |Ctrl-A Encoded ANSI X3.64-subset and CP437 Terminals|
|''.asc''        |Ctrl-A Encoded ANSI X3.64-subset and ASCII Terminals|
|''.ans''        |ANSI X3.64 Color Terminals|
|''.mon''        |ANSI X3.64 Monochrome Terminals|
|''.seq''        |PETSCII Terminals|
|''.rip''        |RIPscrip Terminals|
|''.utf8''       |UTF8|

See the [[https://gitlab.synchro.net/sbbs/sbbs/-/tree/master/text|Menu Directory]] in [[dev:Git]] for the many default menu files and their contents.

===== Customization =====

For customizing your displayable text and menu files, see [[:custom:menu files|Customizing Menu Files]] for details.

===== See Also =====
  * [[:dir:text|TEXT Directory]]
  * [[:custom:menu files|Customizing Menu Files]]
  * [[:custom:atcodes|@-codes]]
  * [[:custom:ctrl-a_codes|Ctrl-A (attribute) codes]]
  * [[:config:|Configuration]]
  * [[:resource:ANSI Editors]]


{{tag>configuration file_type text_file menu}}
