Spiderman revealed his secret identity during Marvel's Civil War story arc. He sided with Tony Stark in favor of mutant/superhero registration and later changed sides and got completely and utterly fucked over. Later Kingpin would hire an assassin that ended up shooting Aunt May. Spiderman did absolutely everything he could to try and save her including seeking help from basically everyone. He was a fugitive at the time so a bunch of people told him to go fuck himself (including Tony) but Jarvis would end up throwing down the cash necessary for her medical care.
So there isn't anyone anywhere that can help Aunt May. So Mephisto comes to Parker in the guise of a little girl and offers to save Aunt May's life if exchange for Spiderman's marriage. There's some back and forth about souls (Mephisto doesn't want his, people who sacrifice themselves in such a manner see their torment as noble and are thus pointless to flay) and eventually Parker goes through with it. Mephisto then reveals what he was really after. Be separating Peter Parker and Mary Jane their daughter to be, May Parker, will never exist. She would have combined the best of both of them and been a powerful force for good. One that Mephisto would prefer never be. That was the form he took when he approached Parker. That of his unborn daughter.
So Peter Parker is back to living with his geezer aunt, he never got married, an entire years worth of continuity involving Spiderman getting organic webshooters by becoming the avatar of spiders (or something, I forget exactly how that went) is wiped away, and Harry Osborne is back alive along with some other small tweaks. Absolutely no one remembers Spiderman's secret identity either. That was part of the deal.
Basically it was all one big excuse to retcon away Peter's marriage and bring the character more in line with the films. Fans hated it. It still gets brought up all the time. It pisses me off because I was really interested in seeing where they were going to take the character after the Civil War and rather than try they pussied out. Years later there would be a sequel (One Moment in Time) where despite massive backlash the One More Day story arc stands and too bad.
Right now Peter Parker and Doctor Octopus have switched bodies and Peter died while in Doc Ock's. Spiderman is actually Doctor Octopus in Peter Parker's body running around pretending to be him. And brainwiped Peter's memories when they surfaced. Peter is also stone dead in the Ultimate universe. The consensus is that Peter just believes he's Doc Ock and it'll all fix itself eventually.