I don't know how PHP CLI works, but you can call a batch script which has the line "pause" - PHP can't complete until that script finishes, and it won't finish until the user presses any key.
At first, when I read this, I dismissed it because I really want the script to be one file, for ease of portability. Then I thought about it, and realized that batch files are just a bunch of command line commands. If the batch file was only going to contain one command ("pause"), that would have the same effect as simply typing "pause" at a command prompt. Well, PHP has functions to execute command line functions, so I ended up with this:
function anykey() {
passthru('pause');
}
Thank you for your help in this matter. I am not sure if Shrike's function would work, as the issue was that the prompt text was displayed, but it continued to accept input until the ENTER key was pressed.
Kyle