The phrases including spitting nickels generally mean to be able to do something impossible or astonishing. Standing on your head and spitting nickels dates from the early 1970s. Plain spitting nickels dates from the 1940s, in an anecdote from the 1910s.
Don't take any wooden nickels is a warning to be careful in your dealings and dates from the 1900s.
Stand on your head and spit wooden nickels
1974 - Traffic World - Volume 160 - Page 95 - Traffic Service Corporation:
As we once said in a prior column, if a duly effective tariff should require the shipper's traffic manager to stand on his head and spit wooden nickels before a particular rate may be applied.
1975 - The Washingtonian - Volume 11 - Page 59:
And I wouldn't start a kid on piano lessons at all until he wanted it so much that he was willing to stand on his head and spit wooden nickels." “We encourage creativity first and then add discipline," says Erika Thimey, founder of the Dance Theatre of Washington.
1975 - Techniques of program structure and design - Page 53 - Edward Yourdon -
They may have been able to make an IBM 1401 stand on its head and spit wooden nickels, but they may not have been familiar with (or even aware of) today's important concepts of top-down design, modular design, structured programming, and so forth.
1975 - A survey of mathematics - Page 9 - Mario F. Triola:
18. If John does not study, then he will not pass.
p: John studies.
q: John will pass.
19. I will stand on my head and spit wooden nickles.
p: I will stand on my head.
q: I will spit wooden nickles.
Stand on your head and spit nickels
1971 - Filmfacts - Volume 14 - Page 174 - University of Southern California. Division of Cinema, American Film Institute, Center for Understanding Media:
NEWSDAY "There are some actors I would enjoy watching even if they stood on their heads and spit nickels. Laurence Olivier is one. George C. Scott is another. I prefer plot and character to gymnastics. But I'll tolerate just about any vehicle that offers one
Do something and/or spit nickels
1974 - What your child is all about - Page 98 - Murray M. Kappelman:
"Doctor, if I have one more teacher look at me and smile that smile and ask, 'Are you Dorothy's sister?' as if I was suddenly expected to sprout wings or spit nickels, I'm going to run away from home."
1972 - The pilgrims - Page 216 - John Asberry McCluskey:
Many a night Ubangi has told the world that he'd walk swamp bottoms for this woman, that he'd drink muddy water and spit nickels for her tender touch.
1967 - Theatre crafts - Volumes 1-2; Volume 1 - Page 21:
We have a rolling scenic unit that does everything but spit nickels. It's used as an integral part of the setting for four shows. The unit had to have lights in it.
1962 - Mirrors are lonely - Page 300 - Uli Beigel:
"Max is very sophisticated," Cameo said. "I suspect Max doesn't listen to you," said Michael. "I heard," Max said. "What should I do, spit nickels?" "Oh, Max," said Cameo.
1961 - Family life plays - Page 299 - Nora B. Stirling:
RUTH: Oh sure, of course. Well, that's just dreamy, Sal, I'm so jealous I could spit nickels.
The following quote was printed in at least six different sources up to 1950, but the earliest I found is a full-view (i.e. verifiable, non-snippet) December 8, 1941 from Life magazine in a profile of General Douglas "MacArthur of the Far East":
MacArthur's record might be summarized by the remark of an A. E. F. private made in 1918: "He's a hell-to- breakfast baby, long and lean, who can spit nickels and chase Germans as well as any doughboy in the Rainbow."
Don't take any wooden nickels
According to Wikipedia:
A wooden nickel, in the United States, is a wood token coin, usually issued by a merchant or bank as a promotion, sometimes redeemable for a specific item such as a drink.
The Wooden Nickel Museum says:
Just when the adage "Don't take any Wooden Nickels!" was added to the American language is unclear, but the reasons are easy to understand. First of all, each wood had an expiration date and generally even a specific final redemption time. If you were in a possession of a handful of wooden nickels that expired at noon today and your best customer came through the door at five minutes to noon, it would be difficult to get to centennial headquarters to cash them in. Many Wooden Nickels also said they had to be unbroken, and the rectangular "Flats" were pretty fragile.
A Dictionary of Catch Phrases (Partridge, Beale, 1985) has it from at least 1918:
don’t take any wooden nickels! is described by W & F as ‘a c. 1920 fad phrase’ and glossed as Take care of yourself protect yourself (a wooden nickel having, of course, no legal value): but this US c.p. lasted right up to WW2 and dates, suspect, since c. 1900. It was adopted by Canadians; Leechman, 1959, remarking in a letter to me, ‘A c.p. of the last fifty years, and still heard occasionally’. And note that in Ring W.Lardner’s The Real Dope, 1919, it occurs in Jack Keefe’s letter of 16 May 1918, thus: ‘In the mean wile’—until we meet again—‘don’t take no wood nickles and don’t get impatient and be a good girlie and save up your loving for me.’ Cf don’t let anyone sell you a wooden nutmeg!
I found it in The Salt Lake Tribune, of May 16, 1906:
A letter received in Salt Lake yesterday
from Jack Herwig, the old outfielder of the
Ogden team, who is now signed up with Butte,
saying that he met with an accident in one
of the game last week and is now in bed.
Jack sends his regards to the bunch and
hopes they will not take any wooden nickels.
Here's some more US newspapers from 1914, 1919, 1920, 1920, 1921 and 1922, showing it's growing popularity as a jocular farewell.
A Dictionary of Catch Phrases says:
don’t let anyone sell you a wooden nutmeg!, later shortened to don’t take any wooden nutmegs!, ‘stems from Colonial days when sharpers or itinerant peddlers in Connecticut sold imitation nutmegs carved out of wood [and] was a common admonition to the unwary’ (W.J.B., 1975; he adds that ‘Connecticut is sometimes called “The Nutmeg
State”’). T.C.Haliburton, in The Clockmaker; or, The Sayings and Doings of Sam Slick, of Slicksville, 1837, mentions ‘the facture of wooden nutmegs,…a real Yankee patent invention’ (Oliver Stonor, 1977). See also don’t take any wooden nickels!
nobody is going to sell me wooden nutmegs. This is a N. Country, esp. Yorkshire, boast of one’s own alertness and freedom from gullibility: since c. 1830. Joan Fleming, Screams from a Penny Dreadful, 1971, has this passage: ‘Better, I thought, take him home and introduce him first to Nanny whose boast always was that “Nobody is going to sell me wooden nutmegs”.’ For both the sentiment and the form, cf the US c.p., don’t let anyone sell you a wooden nickel (or don’t take any wooden nickels), perhaps prompted by the Brit. c.p.