Carpetbagger is the term given to a person who moves from one distinct geographic area to another for the purposes of seeking political office.
 Origins of the term
The term originated after the United States civil war, when many Northerners moved into the South for various reasons. Most of them came to set up schools and help with civil rights work. The "Freeman's Bureau" was especially important, trying to teach both general education and political understanding to African-Americans after the abolition of slavery.
The Southern political cartoons of the time depicted all of the Northerners as failures back home, too poor to afford real luggage, thus bringing everything in bags made of cheap carpet. The Southern whites assumed that all of the Northerners had come to oppress them and set up "Negro government", and waged an insurrection to force them back out. Once Reconstruction ended, so did the "carpetbaggers."
An associated term was "scalawag," which referred to any Southerner who supported the "carpetbaggers".
Reverse carpetbaggers are southerners desperate to move to someplace sane as soon as possible. They have only started to appear recently, usually being college students.
 Meaning in the UK
In the United Kingdom the term was widely used in the mid/late 1990's, at a time when many building societies became banks, meaning their members received a lump sum payment when the society went public. Many people took out accounts with a building society that was expected to turn into a bank in anticipation of such payments, becoming known as carpetbaggers, or, more often, as "greedy little shits" (or "Damnit, wish I'd got in there").