Fix dialog URL

Sometimes the form URL used to generate the dialog URL may contain query strings. For example Translatable appends ?locale=en_NZ to the form. This fix will strip out any query strings and re-append to the url after the LinkID has been added. I have tested this