Chapter 13. Working with the Server Environment
PHP, Apache, and MySQL are not the only applications on your machine, and there may come a time when you need to access those other applications from within your PHP code. In this chapter, you’ll learn some techniques for running programs from within your PHP scripts.
In this chapter, you’ll learn
How to pipe data to and from external applications
How to send shell commands and display results in the browser
By the Way
While the examples in this chapter are best suited for Linux/Unix users, the same principles hold true for Windows users.
Opening Pipes to and from Processes Using popen()
In Chapter 12, “Working with Files and Directories,” you learned how to open a file for reading and writing, using the ...
Get Sams Teach Yourself PHP, MySQL® and Apache All in One, Second Edition now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.