Whether you post a flier or a flyer depends on whether you’re assigning a pilot to an air base or tacking a piece of paper to a bulletin board.
Flyer, first attested hundreds of years ago, was the original agent-noun form of fly, with the obvious meaning of “something that flies.” Later, however, it came to be associated with swift objects, whether airborne or not. This description was widely employed to refer to various vehicles, including trains, planes, and automobiles, as well as boats and ships (and even a submarine, although the name was spelled Flier).
Flyer is also another name for the architectural feature usually called the flying buttress, and it’s the appellation of hockey teams in the United States and throughout northern Europe. In addition, it is used in the sense of financial speculation (because such action is compared to a leap of faith), such as in the phrase “take a flyer.”
However, although that spelling was commonly used as a synonym for pilot (though not until a quarter century after the advent of mechanized flight), the alternate spelling, for some reason, came to predominate in referring to airplane passengers — hence, “frequent-flier miles.”
Long before aviation as we know it first occurred, however, flyer, initially a slang term, became a widespread term for a single sheet of paper posted to advertise or inform. (One source mentions that it was first used to refer to notices in police stations, and that the term was associated with widespread dissemination analogous to a flock of birds taking flight.) Although both spellings are used for this sense, flyer is more common, as flier is the usual spelling in reference to air travel.
Interestingly, two American authorities, Bryan A. Garner, author of Garner’s Modern American Usage, and the Associated Press Stylebook, recommend flier for all senses; however, Merriam-Webster’s Collegiate Dictionary allows that flyer is more common when referring to a leaflet, and popular usage bears this out.
Analogous agent nouns are split in their spelling: Cry becomes crier (though cryer appears in some sources to refer to a court officer who makes proclamations and to a female hawk), but dry becomes dryer and fry becomes fryer. Prier, slier, and sprier are the preferred comparatives of pry, sly, and spry, but pryer, slyer, and spryer are acceptable.
My recommendation for flyer/flier? I’m siding with Merriam-Webster’s, as usual: Pilots and passengers are fliers, and pamphlets are flyers.