chickadee » phricken » match-resource

match-resource resource handlerprocedure

Returns a handler that matches a selector "resource" -- this is just a shortcut for match-selector, matching the directory (posix-string or SRE) you provide as "resource", plus optional subdirectory path.

For example, "/wiki" will match "(/wiki)($|/*)" and provide those two submatches in the request. The handle-file and handle-open-dir handlers expect exactly this.