$ _GET没有使用javascript更新网站

so i have a form set up with multiples 'select' and options like so:

<form>

<select name="box1">
    <option value="1">1</option>
    <option value="2">2 </option>
    <option value="3">3</option>        
</select>

<select name="box2">
    <option value="a">a</option>
    <option value="b">b </option>
    <option value="c">c</option>        
</select>

<input type="submit">
</form>

and i want to retrive the link that would normally be made when you press the submit button but without refreshing the browser so i can let the users copy that link and send it to other people so they can see what options they picked.

i asume this would be possible in javascript but im not sure how and i couldent find any results on google.

I've created a fiddle here: http://jsfiddle.net/wgtVC/1

I'm using jQuery and the serialize() function for forms. This will create the querystring part of the url.

You can then use this to append to the URL where the form should post to.

Here is the code from the link above:

$('form').submit(function(){
    // get the serialized form
    alert($(this).serialize()); // "box1=1&box2=a"

    // append to a string which is the link the form posts to
    link = "http://link.to/my/website";
    alert(link+"?"+$(this).serialize()); // "http://link.to/my/website?box1=1&box2=a"

    return false;
});

In jQuery, there is the serialize function which allow you to do that. You can try this code if you want :

$('form').click(function() {
    parameter = $(this).serialize()
    alert(window.location.pathname + parameter)
})