You're correct, Ser Dontos gives Sansa a hairnet made of purple gemstones. One of the gemstones is actually a crystalline form of poison known as the Strangler. During the wedding Olenna fixes Sansa's hairnet and takes the poison out of her hair. I don't think it's ever revealed how, but presumably either Olenna or Margaery slipped it into Joffrey's wine.

The hairnet is made of Amethyst. If you read the prologue in A Clash of Kings you will know all you need about the item. Maester Cressens uses it to try to take out Mellisandre.

Littlefinger hinted at Lady Ollena being involved in A Feast for Crows. I believe he conspired with her when he was sent to negotiate with the Tyrells on behalf of the crown in ACOK. Ollena heard rumors about Joffrey and Littlefinger probably confirmed her suspicions so they hatched a plan.

Also Littlefinger had the Kettleblacks find the dwarf jousters for Joff as a way to get Tyrion angry and look more suspicious. You see Tyrion was the only person who had knowledge of Littlfinger's manipulations (Valyrion Knife) so he needed to take Tyrion down.

I know all the evidence points to Joffrey being poisoned with the Strangler, but a part of me wants to believe the little berk simply chokes on his bite of pigeon pie, and Pycelle lies through his teeth about the cause of death because he knows what Cersei wants to hear.