fixed the problem you reported and removed a lot of excess redefining of variables.
in the sort order and action they now have the same name for $_get and $_post