Search for new physics with long-lived particles decaying to photons and missing energy in pp collisions at $\sqrt{s}=7$ TeV