Retrieving URL components bug fix

involves bugs:
http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8750
http://pkp.sfu.ca/bugzilla/show_bug.cgi?id=8748