Remove most cgi usage from importxls.cgi