The feed-a-cold idea arose out of a folk understanding of the disease process, namely that there were two kinds of illnesses, those caused by low temperatures (colds and chills) and those caused by high temperatures (fever).
If you had a chill, you wanted to stoke the interior fires, so you pigged (feed a cold). If you had a fever, you didn't want things to overheat, so you slacked off on the fuel (starve the fever).