Finally settled on a method that would allow handling post vatiables, as it is easy to send post variables with javascript