mod_search: Use binary parsing of stored query resource

This elimintates the conflict where hasobject/hassubject would use lists
for arguments (e.g. [subject, predicate]), which is a limitation of how
search queries are used in the template system. Two/three-letter queries
stored in resources would break (e.g. hasobject=joy); this is no longer
the case.

(cherry picked from commit 209490d9025714b70eb2077f4e16bd508f717f56)