Page 373 - Beginning PHP 5.3
P. 373

Chapter 11: Working with Files and Directories
                           In the next chapter you are introduced to another popular way of storing application data: databases.
                         This is quite a big topic, so it ’ s spread over the next three chapters. Chapter 12 introduces the concept of
                         databases; Chapter 13 shows how to read data from a database; and Chapter 14 shows how to
                         manipulate data in a database.

                           Before leaving this chapter, try the following exercise to test your knowledge of file and directory
                         handling in PHP.  You can find the solution to this exercise in Appendix A.



                           Exercise

                           Create a PHP application that can be used to find a particular directory by name when given a top - level
                         directory to search. Make the application look through the given directory, as well as all directories
                         under the given directory.


















































                                                                                                         335





                                                                                                      9/21/09   9:10:24 AM
          c11.indd   335
          c11.indd   335                                                                              9/21/09   9:10:24 AM
   368   369   370   371   372   373   374   375   376   377   378