In a large part of Europe, before hops were used, beer was flavored with Gruit. Quoted from wikipedia: Gruit was a combination of herbs, commonly including sweet gale (Myrica gale), mugwort (Artemisia vulgaris), yarrow (Achillea millefolium), ground ivy (Glechoma hederacea), horehound (Marrubium vulgare), and heather (Calluna vulgaris). The specific herbs that made up any given Gruit could vary.
http://en.wikipedia.org/wiki/Gruit
Edit: An intriguing anecdote, the Gruuthuse family, who were Flanders nobility and masters of the famous Gruuthuse house in Bruges owed their name and lively hood to a tax on Gruit but in the forteenth century Gruit started to fall out of favor as hops became popular so the tax they collected was changed from a tax on Gruit to a tax on beer.
This is not meant to be a top-level comment, as I am not an historian. Caveat lector.
One major factor in the dominance of hops in European beer was the Bavarian purity law of 1487 and 1516. It mandated that only three ingredients be used in beer: water, barley and hops. It was made to prevent competition between brewers and bakers for ingredients, as brewers using wheat and rye in beer were driving up the price of bread.
The reason hops were chosen over gruit was simplicity and consistency. No two gruits were exactly the same, as it was a wide mix of herbs meant to both preserve and bitter a beer. Some brewers began to add preservative ingredients which were actually somewhat troublesome, such as soot and fly agaric. Using hops also preserves beer, and bitters it quite effectively as well. Choosing a single plant that accomplishes everything you need from gruit makes for significantly simpler enforcement, made even more simple by the fact that hops had already been more common for centuries.
I have read suggestions that gruit was phased out in favour of hops due to the Reformation. As Protestantism spread, more and more nobles and their respective populations began to cut ties with the Roman Catholic Church - which happened to have a monopoly on gruit. The simplest alternative to monastically-provided gruit was hops. However, hops was already favoured in the Holy Roman Empire hundreds of years before the Reformation (Source), so I suspect this is not the only factor. I would expect that if this hypothesis were true, predominantly Catholic regions would favour gruit and predominantly Protestant regions would favour hops. However, to my knowledge this is not so. As far as I know the eschewing of gruit for hops was somewhat universal.
I welcome someone with more extensive knowledge to correct and expand further.