Kill Safari by double-tapping on the Home button. Locate Safari in the task bar, then slide the Safari mini-page upwards so it vanishes.
Tap Settings > Safari > Clear History and Website Data. Next, locate Security section and slide the “Block Pop-Ups” switch to the On position.
Press the Home button to return to your Home screen.
If this doesn’t help, then reset your device. It won't delete your data. Press and hold down the On/Off button and the Home button until the display turns off and returns with the Apple logo showing.