I can't find whether this is documented in the perldoc, but when CGI sees a param that is multi-valued, it appears that the values retain their ordering from the query string. So as long as all your fields are single-valued, you can just join the three query strings (in the order GET, POST, cookie) and pass it to CGI. When you then call param in scalar context, you will get the first appearance of that param in the combined query string.