Chapter 9. Working with Objects


Objects are used to store and organize data. Object-oriented programming structures found in many programming languages are also evident in PHP; however, in PHP it is not required that you write your scripts in an object-oriented manner. Many PHP scripts, in fact most of the ones you will find in this book, are procedural rather than object-oriented. If you are coming to PHP with a background in object-oriented programming, this chapter will help you to understand the object model in PHP. If you are new to programming altogether, it's important to understand the basics of object-oriented programming, but you might want to gain experience in procedural programming and the fundamentals of the PHP language before you tackle a topic that has entire books written on it.

In this chapter, you learn the basics of working with objects, including

  • Understanding the basic structure of an object

  • How to create and manipulate objects and the data they contain




Sams Teach Yourself PHP, MySQL And Apache All in One
Sams Teach Yourself PHP, MySQL and Apache All in One (3rd Edition)
ISBN: 0672328739
EAN: 2147483647
Year: 2004
Pages: 327

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net