This has been a bad couple of weeks for mobile phone security as several major iPhone vulnerabilities were revealed this week which allow a malicious external website to compromise your phone when it is viewed, either in Safari or another app that renders HTML (and there are many, many apps that do).
As such, it is imperative that iPhone users apply the latest updates for iOS as soon as possible. The fixed version is iOS 8.4.1, so any iPhones running iOS versions less than 8.4.1 are vulnerable.