What is the minimum and maximum length of a search URL?
I'm noticing big urls when entering search terms. How big can these urls get? Can this be changed?
I'm noticing big urls when entering search terms. How big can these urls get? Can this be changed?
Replies
Low 3 Jun 2014 19:03
The encoded URI-segment is the actual search query, but encoded to be URI-safe. The more input fields in your form, the larger the query segment will be. This approach makes the URLs shareable and persistent.
So, the only way to reduce this, is to reduce the amount of input fields. This is not always possible, but you could see which fields are supposed to be changed by the user (like keywords) and which ones aren't (status, or perhaps require_all).
There isn't a minimum or maximum length, but the latter may depend on server configuration.
Another option might be to use GET vars instead (not encoding the query in the settings), but whether that's possible also depends on your server config.