Change the DPI of a Jpeg Image with PHP
Recently I was finishing a QR Code generator, and I had to prepare two versions of the generated files - for web (72DPI) and for print (300DPI). The first option is working right out of the box for GD Library. That is because the default value of the 72DPI is hard-coded in the config file