This week's book giveaway is in the OO, Patterns, UML and Refactoring forum. We're giving away four copies of Refactoring for Software Design Smells: Managing Technical Debt and have Girish Suryanarayana, Ganesh Samarthyam & Tushar Sharma on-line! See this thread for details.
Setting window.location is different from calling form.submit(). The former will always do a GET, while the latter -which is what the code you posted is doing- will use whatever the form's action attribute is set to.
The only way to keep parameters out of the URL is to use POST. So if that's the paramount requirement, then you'll need to adapt the code that's forcing you to do a GET.
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
subject: How to hide the parameters shown in the url while submitting a form