Sounds more like a question for Stackoverflow, to be honest.