O'Reilly logo

PHP Advanced for the World Wide Web: Visual QuickPro Guide by Larry Ullman

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

Adding Text to PDFs

Obviously, you'll want to do more with your PDFs than just generate blank documents. The most important thing to be able to do is to add text, which you'll learn here.

Placing text within PDF documents is not nearly as easy or straightforward as you might think. Text cannot just be written down the page from left to right, top to bottom, as you can in your text editor or Web browser. Text in PDFs must be placed on the page as you would place points and lines on a graph. In fact, you can place the text in nearly any order and result in the same page (assuming no overlaps), but I still find it makes the most sense to code your way from the top down.

One of the trickier aspects of PDF generation is that the lower-left corner ...

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