SHOUTBOX — INSTALL GUIDE (plain text)
========================================

Created by Sarutobi for Animehistory.org
https://animehistory.org/

This guide helps you put the shoutbox on a web host or run it on your
own computer. You do not need to be a programmer.


WHAT YOU NEED
-------------

  * PHP 8.0 or newer (8.1+ recommended)
  * The PHP SQLite extension (usually enabled on most hosts)
  * A web browser


OPTION A — SHARED WEB HOSTING (cPanel, Plesk, etc.)
----------------------------------------------------

1. On your computer, open the shoutbox folder. It contains files such as
   index.php, api.php, config.php, assets/, lib/, and data/.

2. Upload the ENTIRE shoutbox folder to your website using FTP, SFTP, or
   your host's File Manager. Example destinations:
     public_html/shoutbox/
     www/shoutbox/
     htdocs/shoutbox/

3. Set folder permissions so PHP can write the message database:
     - Folder "data" → writable by the web server (often chmod 755 or 775)
   If posts fail with a database error, try chmod 775 or 777 on "data"
   (777 is less secure; use only if your host requires it).

4. Open the shoutbox in your browser:
     https://YOUR-DOMAIN.com/shoutbox/
   (Use the path where you uploaded the files.)

5. Type a message and click "Shout!" to test. If it works, you are done.


OPTION B — RUN ON YOUR COMPUTER (LOCAL DEMO)
--------------------------------------------

1. Install PHP if you do not have it:
     - Windows: https://windows.php.net/download/
     - Mac: often pre-installed, or use Homebrew (brew install php)
     - Linux: use your package manager (e.g. sudo apt install php sqlite3)

2. Open a terminal / command prompt.

3. Go into the shoutbox folder. Example:
     cd /path/to/shoutbox

4. Start PHP's built-in web server:
     php -S localhost:8080

5. Open your browser to:
     http://localhost:8080/

6. Press Ctrl+C in the terminal to stop the server when finished.


FILE PERMISSIONS (QUICK REFERENCE)
----------------------------------

  data/          must be writable (messages stored in data/shouts.sqlite)
  other files    normal read-only for visitors is fine


TROUBLESHOOTING
---------------

  Blank page or "500 error"
    → Check that PHP 8+ is selected in your hosting control panel.

  "Could not post" or database errors
    → Make sure the data/ folder exists and is writable.

  Shouts do not update for other people
    → Refresh once; the page polls every few seconds automatically.
    → Some hosts block long polling; normal refresh should still show posts.

  SQLite not available
    → Ask your host to enable pdo_sqlite, or move to a plan that includes it.


CREDITS
-------

  Shoutbox software by Sarutobi
  Animehistory.org — https://animehistory.org/

For feature notes and BBCode help, see readme.txt in this same folder.
