3v4l.org

run code in 150+ php & hhvm versions
Bugs & Features
<?php $input = "Alien"; echo str_pad($input, 10); // produces "Alien " echo str_pad($input, 10, "-=", STR_PAD_LEFT); // produces "-=-=-Alien" echo str_pad($input, 10, "_", STR_PAD_BOTH); // produces "__Alien___" echo str_pad($input, 6 , "___"); // produces "Alien_" ?> <?php
Output for 5.4.0 - 5.5.8
Parse error: syntax error, unexpected end of file in /in/gYh2m on line 8
Process exited with code 255.
Output for 4.3.0 - 5.3.29
Alien -=-=-Alien__Alien___Alien_<?php