2025-07-24 22:27:13 -06:00
|
|
|
# php
|
|
|
|
|
|
|
|
|
|
> PHP command-line interface.
|
2025-12-16 10:20:31 -07:00
|
|
|
> Meer informatie: <https://www.php.net/manual/en/features.commandline.options.php>.
|
2025-07-24 22:27:13 -06:00
|
|
|
|
|
|
|
|
- Parse en voer een PHP-script uit:
|
|
|
|
|
|
|
|
|
|
`php {{pad/naar/bestand}}`
|
|
|
|
|
|
|
|
|
|
- Controleer de syntax van (d.w.z. [l]int) een PHP-script:
|
|
|
|
|
|
|
|
|
|
`php {{[-l|--syntax-check]}} {{pad/naar/bestand}}`
|
|
|
|
|
|
|
|
|
|
- Voer PHP inter[a]ctief uit:
|
|
|
|
|
|
|
|
|
|
`php {{[-a|--interactive]}}`
|
|
|
|
|
|
2025-12-16 10:20:31 -07:00
|
|
|
- Voer PHP-code uit (Opmerkingen: Gebruik geen `<? ?>` tags; escape dubbele aanhalingstekens met backslash):
|
2025-07-24 22:27:13 -06:00
|
|
|
|
|
|
|
|
`php {{[-r|--run]}} "{{code}}"`
|
|
|
|
|
|
2025-12-16 10:20:31 -07:00
|
|
|
- Start een PHP ingebouwde webserver in de huidige map:
|
2025-07-24 22:27:13 -06:00
|
|
|
|
2025-09-14 18:48:49 -06:00
|
|
|
`php {{[-S|--server]}} {{host}}:{{poort}}`
|
2025-07-24 22:27:13 -06:00
|
|
|
|
|
|
|
|
- Toon geïnstalleerde PHP-extensies:
|
|
|
|
|
|
|
|
|
|
`php {{[-m|--modules]}}`
|
|
|
|
|
|
|
|
|
|
- Toon informatie over de huidige PHP-configuratie:
|
|
|
|
|
|
|
|
|
|
`php {{[-i|--info]}}`
|
|
|
|
|
|
|
|
|
|
- Toon informatie over een specifieke functie:
|
|
|
|
|
|
|
|
|
|
`php {{[--rf|--rfunction]}} {{functie_naam}}`
|