O'Reilly logo

Learn PHP 7: Object-Oriented Modular Programming using HTML5, CSS3, JavaScript, XML, JSON, and MySQL by Steve Prettyman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 3

image

Modular Programming

“Yes, I am a terrible coder, but I am probably still better than you :)”

—Rasmus Lerdorf

Chapter Objectives/Student Learning Outcomes

After completing this chapter, the student will be able to:

  • Create an error-free simple objected-oriented (OO) modular PHP program
  • Create a PHP class and make an instance of the class (object)
  • Create an OO PHP encapsulated program, including GET and SET methods
  • Create PHP methods (functions) that accept parameters and return information
  • Create PHP public and private properties (variables)
  • Import existing PHP code from another file or library into a program
  • Validate information received ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required