1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-08-12 17:15:46 +02:00
tldr/pages/common/php.md
Jefferson Ventura 9012dcf098
php: add pt_BR translation (#17415)
Co-authored-by: Renie Siqueira <reniedev.github@3nie.com>
Co-authored-by: Managor <42655600+Managor@users.noreply.github.com>
Co-authored-by: Sebastiaan Speck <12570668+sebastiaanspeck@users.noreply.github.com>
2025-08-10 11:23:28 +03:00

752 B

php

PHP command-line interface. More information: https://php.net.

  • Parse and execute a PHP script:

php {{path/to/file}}

  • Check syntax on (i.e. [l]int) a PHP script:

php {{[-l|--syntax-check]}} {{path/to/file}}

  • Run PHP inter[a]ctively:

php {{[-a|--interactive]}}

  • Run PHP code (Notes: Don't use tags; escape double quotes with backslash):

php {{[-r|--run]}} "{{code}}"

  • Start a PHP built-in web [S]erver in the current directory:

php {{[-S|--server]}} {{host}}:{{port}}

  • List installed PHP extensions:

php {{[-m|--modules]}}

  • Display information about the current PHP configuration:

php {{[-i|--info]}}

  • Display information about a specific function:

php {{[--rf|--rfunction]}} {{function_name}}