The examples from Muhammad's hair and the other mentioned actually have their roots from this more ancient example in the Bible:
"And it came to pass, as they were burying a man, that, behold, they spied a band of men; and they cast the man into the sepulcher of Elisha: and when the man was let down, and touched the bones of Elisha, he revived, and stood up on his feet." 2 Kings 13:21