I've seen (had) it done where the weft is glued around the hair...not your actual hair, but a single weft is wrapped around the actual hair and then the remaining tracked/weft hair is glued around that. The weft hair could probably be glued around the baggie as well.
Only do this if you want to keep the phony pony in for a good while for security or want to avoid the bobby pins. Those pins would scratch/pinch my scalp something fierce!