One of the funniest writers I've ever read and the reason I bought a subscription to The San Francisco Chronicle at the tender age of 17 many years go is Herb Caen (1916-1997) - https://en.wikipedia.org/wiki/Herb_Caen.
His column was an almost daily rapid fire barrage of witticisms and insight into one of my many homes SF.
And he gave The City one of its most well-known nicknames – "Baghdad-by-the-Bay" – in several of his columns. The name caught on and is commonly used as SF's alter-ego. Unfortunately "Crazytown USA" never did...
Baghdad-by-the-Bay is a decidedly 1001 Nights related nickname and from its uses below one can easily still imagine Haroun and co. wandering around Polk and Pine getting into all sorts of Nights-esque problems.
Herb's obituary and some of his greatest quips can be read online at the (somewhat ad-heavy) SFGATE page - http://www.sfgate.com/news/article/7-Decades-of-Baghdad-By-the-Bay-Tied-Together-2855480.php
From October 1940:
"The inner excitement of Stockton tunnel, as the jampacked F-cars wiggle noisily through, autos somehow squeeze past, and school kids run excitedly along the inside walk; and North Beach, with its 1001 neon-splattered joints alive with the Italian air of garlic and juke-box wail of American folk songs. . . The dismal reaches of lower Market after midnight; the city within a city that is the deep Mission District, and the bittersweet juxtaposition of brusquely modern Aquatic Park against the fortresslike jumble of red brick where Ghirardelli makes its chocolate.
The crowded garages and the empty old buildings above them, the half-filled night clubs and the overfilled apartment houses, the saloons in the skies and the families huddled in the basements, the Third Street panhandlers begging for handouts in front of pawnshops filled with treasured trinkets, the great bridges and the rattletrap streetcars, the traffic that keeps moving although it has no place to go, the thousands of newcomers glorying in the sights and sounds of the city they've suddenly decided to love, instead of leave.
...This is Baghdad-by-the-Bay!"
"Hello, Visitors!By Herb Caen
Greetings and welcome to San Francisco, city of the world, worlds within a city, forty-nine square miles of ups and downs, ins and outs, and going around in circles, most of them dizzy. A small “d” democratic city run by big-buck conservatives, a place where the winds of freedom will blow your mind and your hat off, where eccentricity is the norm and sentimentality the ultimate cynicism. Cable cars and conventions, boosterism living uncomfortably with sophistication, a built-in smugness announcing simply that we are simply the best. The only city better than San Francisco today was San Francisco yesterday–maybe. Remember, visitors, that you are lucky to be here. Have fun. Spend money. Marvel at our giddy combination of Kookville and High Kultur, busyness and booziness, millionaires stepping daintily over passed-out winos, hot-pantzed ladies of the night throwing themselves at your passing car. Enjoy yourselves, but don’t stay too long. Parking is such street sorrow.
Years ago, this wide-eyed kid from Sacramento dubbed it Baghdad-by-the-Bay, a storybook city of spires and minarets, gay banners fluttering in the breeze. A viewtiful city, he called it, a Saroyanesque pastiche of lovable gamblers and boozy bohemians spouting half-aphorisms in saloons run by patrician publicans. The most beautiful bay in the world–only superlatives were accepted–was breasted by ferries that looked like Victorian mansions with sidewheels. Then came the greatest bridges in the world–“the car-strangled spanner” of the bay and Joe Strauss’s suspenseful “bridge that couldn’t be built.” We looked around at the wonderful, funderful city and we were proud to be San Franciscans, the envy of all.
San Francisco, Queen City of the Pacific (the title was once non-ironic), gleaming jewel of the West Coast, surrounded on three sides by water and on the fourth by Republican reality. Occasionally a Republican mayor sneaks in, but it is essentially a city that votes the straight Demo ticket. I don’t even know how they get people to run for mayor: who wants to be Chief Kook of Kookville? We have a city father who is an unmarried mother of two and a gay seat on the Board of Supes, as befits the new demographics. San Francisco has a large gay population, and it keeps increasing, although exactly how gays multiply has not been explained. Nothing is ever explained in San Francisco.
“The city that was never a town.” There’s a thought that appeals to San Franciscans. Will Rogers may or may not have said it, but the phrase does conjure up a flash of the crazed and crazy place that was born in a Gold Rush and grew up overnight to become a fabled city. Tip to visiting journalists: “The coldest winter I ever spent was one summer in San Francisco” was one of the best lines Mark Twain never wrote, but who cares. Whoever said it was accurate enough.
Welcome visitors, to a city as confusing as the Democratic party. If you drive, don’t drink, but the driving will drive you to drink. We are casual about street signs, but you might find one if you look hard enough. Directions? Forget it, and don’t ask whatever looks like a resident. He won’t know either. If you keep going on a one-way street, you will soon come to another one-way street with traffic coming right at you. That’s what makes us colorful and our insurance rates the highest. Don’t worry about traffic lights. Green and red both mean go like hell; in fact you cross on the green at your own risk. Another tip: No Parking Any Time means park any time, usually on the sidewalk and sometimes on a pedestrian. There are a lot of tow-away zones, so check the signs. It is maddening to pay $60 to ransom your car from a towing company whose slogan is “Discover San Francisco”.
San Francisco, a city for all seasons (sometimes four in one day) and various reasons. A city that thinks nothing of spending $60 million to rebuild a cable car system that was obsolete a century ago and even less of letting drunks lie on the street as long as they aren’t in the way of the cables; “a sociological, not a police problem,” unquote. A city of soup kitchens and two thousand restaurants, some of them excellent and most of them crowded. A place where whites are a minority and “the largest Chinatown outside of the Orient” is no longer large enough. The mayor and both congressmen are Jewish women; do we need a Yenta Control Board?
So welcome, dear visitors, to Crazytown USA. You will either be crazy about it or become as crazy as the rest of us. Either way, may you all return safely to your funny country, that large land mass slightly to the right of Baghdad-by-the-Bay."