PHP Classes

File: scripts/CLAUDE.md

Recommend this page to a friend!
  Packages of Matthew Asham   Binkterm PHP   scripts/CLAUDE.md   Download  
File: scripts/CLAUDE.md
Role: Auxiliary data
Content type: text/markdown
Description: Auxiliary data
Class: Binkterm PHP
Bulletin board system based on the Web
Author: By
Last change:
Date: 5 days ago
Size: 746 bytes
 

Contents

Class file image Download

CLI Scripts

  • All PHP scripts in this directory must include the shebang line `#!/usr/bin/env php` at the top.
  • CLI scripts must include `src/functions.php` after autoload to access global functions like `generateTzutc()`: `require_once __DIR__ . '/../src/functions.php';`
  • Do not use `PHP_BINARY` from web requests to launch CLI scripts. Under php-fpm it points at the FPM SAPI, not the CLI interpreter. Invoke executable scripts directly via their shebang, or use a real CLI `php` path when you explicitly need the interpreter.
  • Scripts must be made executable with `chmod +x` and marked as executable in git with `git update-index --chmod=+x scripts/filename.php`.
  • When adding or removing a script in `scripts/`, update `docs/CLI.md`.