These early attempts are all incorporated in doPLs.php.
BTSOM.
Merge branch 'master' of https://github.com/RobCranfill/ccam