A PHP mess detector that checks for common potential problems. More information: https://github.com/phpmd/phpmd.
phpmd
phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}}
phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}} --minimumpriority {{priority}}
phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}} --suffixes {{extensions}}
phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}} --exclude {{directory_patterns}}
stdout
:phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}} --reportfile {{path/to/report_file}}
phpmd {{path/to/file_or_directory}} {{xml|text|html}} {{rulesets}} --strict