This is one of those situations where I feel like I'm missing a crucial keyword to find the answer on Google...
I have a bag of parameters and I want to make the browser navigate to a GET URL with the parameters. Being a jQuery user, I know that if I wanted to make an ajax request, I would simply do:
$.getJSON(url, params, fn_handle_result);
But sometimes I don't want to use ajax. I just want to submit the parameters and get a page back.
Now, I know I can loop the parameters and manually construct a GET URL. For POST, I can dynamically create a form, populate it with fields and submit. But I'm sure somebody has written a plugin that does this already. Or maybe I missed something and you can do it with core jQuery.
So, does anybody know of such a plugin?
EDIT: Basically, what I want is to write:
$.goTo(url, params);
And optionally
$.goTo(url, params, "POST");
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…