Allow query parameters in the script URL. Closes #1999.