Chapter 8. USING THE PAGENAVIGATOR CLASS

In this chapter we'll use the PageNavigator class to step through a directory of images reduced on the fly using the ThumbnailImage class. We'll use all three of the classes you have developed so far:

  • The DirectoryItems class stores a list of filenames of images.

  • The ThumbnailImage class reduces the dimensions of each image.

  • The PageNavigator class steps through these images in an orderly fashion.

We'll also look at how to use CSS classes to adjust the appearance of the page navigator; this will greatly improve the reusability of the class. (This isn't directly related to object-oriented programming [OOP], but if a class's appearance cannot blend with various different designs, then its usefulness—and reusability—is ...

Get Object-Oriented PHP 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.