I know PHP is usually used for web development, where there is no standard input, but PHP claims to be usable as a general-purpose scripting language, if you do follow it's funky web-based conventions. I know that PHP prints to stdout
(or whatever you want to call it) with print
and echo
, which is simple enough, but I'm wondering how a PHP script might get input from stdin
(specifically with fgetc()
, but any input function is good), or is this even possible?
Question&Answers:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…