I was in the photo. The only time you would use "on the photo" would be in something like "don't put your books down on the photo" or "don't spill coffee on the photo."
Objects which contain information (photos, pictures, books, magazines, musical scores, ...) can be looked at in two ways: as physical objects or as the information contained in them.
It's almost always on the object, but in the information content. Khoff has already illustrated this.
I sat on the photo. I sneezed on the book. She set the vase on the magazine.