This method actually works—I tried it myself, having been stimulated by a combination of scientific curiosity and the lack of a corkscrew, not necessarily in that order.
Begin by pressing a book against a wall. Then strike the bottom of the bottle against the book. I recommend holding the bottle with a towel and wearing protective glasses to prevent injury should the bottle break (anyone doing this with a champagne bottle risks winning Darwin's award). With repeated strikes, the cork will inch out, bit by bit, so that eventually it can be pulled out by hand.
I did this as a student a long time ago, back in the Soviet Union, sacrilegiously using a volume of Lenin's collected works. It was a good book—for my purpose, at least— although a corkscrew would have been better.1
Question. What drives the cork out of the bottle?
1 The economic policies advocated in Lenin's volume led to shortage of many things, probably corkscrews among them, and caused that volume to be used instead of the corkscrew. This is a rare example of historical justice.