"A number of prodigal currie favours, who by flatterie set him aloft."
-- Raphael Holinshed, 1577 (OED).
Yet another of those incomprehensible English idioms. Although not so very incomprehensible in this case; the verb "to curry" means to rub down and comb a horse. As you might imagine, the horse likes this attention, and will presumably like the person who is currying it. Likewise, if you were to metaphorically "curry" a person, they too would like you! So... currying a person gains their favor. Makes sense, right?
English likes using touch to refer to gaining another's favor. The verb "to flatter" probably comes from the Old French flate-r, meaning "to flatten down or smooth", with the implication of "stroking with the hand", that is, to caress (The modern French flatter is still used in this sense). 'Butter up' was meant just like it sounds -- when butter was a luxury, spreading butter on something made it better. Not quite as pleasant as being stroked, but tastier!
In the 1800-1900s we focused on the idea that the mouth should be involved, and hence we have 'to suck up', 'to kiss up to', to be an 'ass kisser', and eventually a 'brown noser'. Of course, our oral fixation does have deep roots; back in the 17th century we had lick-spittles, those who would lick the spit of their idols off the ground (figuratively, I hope). The anal fixation seems to be more modern.
It's no fun to learn English as a second language...