Download PHP on https://www.php.net/downloads.php
Open your terminal and you have to be in the directory that has the .php file, then run "php -S localhost:8080" on your terminal. Fire up your favorite browser and type in "http://localhost:8080/simple_cmd_inj.php", and you're good to experience out the role of a hacker.