Back in 1972, when New York City was a post-apocalyptic hell hole overrun by crime and on the verge of bankruptcy, architect Peter Blake opined that to save it, the government should be banished and Manhattan should instead be turned over to an unlikely savior.

Walt Disney Productions.

“The only new towns of any significance built in this country since World War II are Disneyland . . . and Disney World,” Blake wrote in New York magazine.

Can you imagine what Disney would have done with all those porn shops in Times Square?

OK, of course you can, but as strange as it sounds today, Blake was not alone in considering the late Walt Disney one of America’s premier urban planners and futurists.

This somewhat forgotten side of Disney is paid homage in Friday’s “Tomorrowland,” a sci-fi adventure that’s grounded in Uncle Walt’s optimistic outlook and love of science.

“I felt like we owed something to his idea of futurism,” screenwriter Damon Lindelof tells The Post. “Walt [contributed to the war effort] in World War II and had every reason to believe that mankind was doomed. Yet he made Disneyland, and he believed in the power of imagination and how it could be used for the betterment of the world.”

“Tomorrowland” centers on a teen science enthusiast (Britt Robertson) who is given a magic medallion that allows her to glimpse a utopian city from another dimension. After learning that the alternate world — and our own — is threatened with destruction, she teams with a crusty inventor (George Clooney) to save Tomorrowland.

The film’s message is that, through innovation, the future will be a lot prettier than, say, “The Hunger Games.” Or “The Walking Dead.” Or the 10 million other post-apocalyptic properties out there.

“I love dystopia, but I’m like, ‘Enough apocalypse,’ ” Lindelof says. “I feel people will appreciate dystopia more if they see the alternative.”

The film began during a meeting between Lindelof and a Disney executive. The writer mentioned he wanted to see a film named after Tomorrowland, one of the themed areas at Disney amusement parks.

Lindelof says he knows basing a script on a ride is probably not the purest start for art.

“When I heard they were making ‘Pirates of the Caribbean,’ it was like, ‘Oh, my God! They’re making a movie out of a ride?’ ” he says. “But when my son, who’s 8 years old, goes on Pirates of the Caribbean, he thinks the ride is based on a movie. That’s an interesting piece of retcon [retroactive continuity], and it leaves a lot of space for original storytelling.”

In truth, Tomorrowland, which was intended to showcase the way we’d live in the future (originally the year 1986), has never been one of the bigger draws at the parks.

“When it opened in 1955, it was almost an afterthought. The kind of thinking you saw at other parts of Disneyland was not there,” says Michael Barrier, an animation historian and author of “The Animated Man: A Life of Walt Disney.” “Tomorrowland was always problematic. You can’t leave it the way it is, because tomorrow has come and gone.”

On (Disney’s) deathbed, he was looking up at the ceiling and pointing out how the city would be laid out. - Director Brad Bird

“It demands constant reinvention,” director Brad Bird tells The Post. “A businessman may find that a constant headache, but Walt was excited by that.”

Tomorrowland did give visitors some of their first looks at out-there tech, including microwave ovens and TV remotes. Disney’s company WED Enterprises also provided a glimpse at the future of robotics during the 1964 New York World’s Fair. The company created four exhibits, including “It’s a Small World” and one featuring an animatronic Abraham Lincoln.

Walt’s real passion lay beyond gadgets, however. Toward the end of his life (he passed away in 1966), he developed a preoccupation with creating the city of the future.

“What happened was, Disneyland was a wildly successful piece of urban planning,” Barrier says. “It was very carefully organized with the flow of traffic throughout the park. There was concern with what was happening with the cities, and Walt looked into what might be done to save them.”

He called his solution EPCOT — Experimental Prototype Community of Tomorrow.

He’d bought a huge tract of land in Florida and set about planning a massive development that would include a built-from-scratch city, and, oh, yeah — an amusement park. Of course, the amusement park was the only thing that became a reality, because Disney shareholders love those $100 entrance fees. But the futuristic city was Walt’s true concern.

“On his deathbed, he was looking up at the ceiling and pointing out how the city would be laid out. And the fact that he was, to his last moments, dreaming about this future and making crazy ideas happen . . . was very moving to me,” Bird says.

EPCOT was to be constructed as a series of concentric rings. High-rises in the center, followed by apartments blocks, churches, retail, park space and finally, on the outer edge, stand-alone houses. All the car traffic was to be kept to underground tunnels, and commuting would be done on electric monorails. The entire middle area was to be climate-controlled, covered by a clear dome.

“I don’t believe there’s a challenge more important than finding solutions to the problems in our cities,” Disney said in 1966.

Someone get those Imagineers working round-the-clock on the R train.