Explain the difference between exec() vs system() vs passthru() ?
Explain the difference between exec() vs system() vs passthru() ?
In PHP, the exec()
, system()
, and passthru()
functions are used to execute external programs, but they handle the output differently:
exec():
FALSE
on error.$output = exec('ls -l');
echo $output;
system():
FALSE
on error.system('ls -l');
passthru():
middle
Gợi ý câu hỏi phỏng vấn
Chưa có bình luận nào