While Apple has technically enabled the printer function on iPhones, iPads, and iPod Touches, printing only works currently on 18 specific models of HP printers.
AirPrint Activator
To enable printing to any printer attached to your Mac, use the free AirPrint Activator (formerly AirPrint Hactivator).
It’s a simple program. I’ve been using a beta of version 2 without problems.
PDF Printing
You can print to a PDF by downloading and installing the CUPS-PDF Installer. Share that printer for it to show up on your AirPrint Activator list.
Automator to Move the PDF / Dropbox
The CUPS-PDF Installer prints to your folder:
/Users/Shared/CUPS-PDF/[your account]
or, for iOS devices, to:
/Users/Shared/CUPS-PDF/ANONYMOUS
Those aren’t easy places to find your PDF, so we’ll automatically move those files when they arrive.
Open Automator (Applications – Automator), then select the “Folder Action” template. This will allow you to choose the CUPS-PDF folder where your printed files go by default. Then drag over the library action “Move Finder Items” and choose where you want the file moved to. You might want to move the file to your desktop. I chose to move the files to a Dropbox sub-folder called CUPS Print Jobs, automatically backing them up and making them accessible to me through the Dropbox app or GoodReader app on my iPhone and iPad.
I set up this Automator action for both my CUPS folders that are printed to, the folder from my user account (used when printing to CUPS-PDF from my Mac) and the ANONYMOUS folder (used when printing to CUPS-PDF from iOS devices).
In order to allow Automator to move files from the ANONYMOUS folder, you need to go to it in the finder (/Users/Shared/CUPS-PDF/ANONYMOUS), CTRL-click on it, select Get Info and add yourself to the permissions for that folder.
Other Options
If these instructions are too much for you and you have $19.95 burning a hole in your pocket, you can do the same thing with Printopia 2.
These features also should be appearing in updates from Apple at some point in the future.