How do you get a Gengar from a trade? You have to evolve a Haunter by trading one to you - a Haunter alone is not going to work. I have looked everywhere in Pokémon Y to find someone to trade a Haunter to me, since I have a Gengarite.
There is no NPC in Pokémon X or Y that will trade you a Haunter. In order to get a Gengar, you simply have to trade Pokémon with someone who gives you a Haunter (or just trade your own Haunter two times).
This means that you have to trade with another human in order to obtain a Gengar. This can be done via the internet or local wireless communication. You can technically receive a Haunter or Gengar from Wonder Trade, but the chance of that is very low. If you're lucky, you might even find a reasonable trade on the GTS! Your best bet, however, is finding a friend who owns Pokémon X or Y.
Once you are able to trade with someone, simply catch a Haunter on Route 14, Route 19, in Frost Cavern or at Victory Road and use it for trading.
For pokémon who evolve through trading, the GTS is going to be your best bet. You are not the only person in the world who wants to evolve a Haunter and there are usually quite a few people offering a Haunter in exchange for a Haunter. If you can't find one, offer up your own Haunter, asking for a Haunter in exchange. You should get a taker in short order.
You can also use this technique to evolve Kadabra, Graveler, Machoke, Boldore, Gurdurr, Phantump, Pumpkaboo or Karrablast and Shelmet (Just remember to ask for the other pokémon for these latter two). Unfortunately, you can't ask for a specific held item when using the GTS, so you will need to coordinate with another player if you want to evolve one of the pokémon that needs to hold a specific item to evolve.