For the url purl_proccessor it will continue to parse a URL until it hits a chunk of the url that does not have a modifier.

I can see how this could be useful in some cases.

However I am using purl with spaces_og and would like to have a way to tell purl to only match the first chunk of the path since only one "space" can be active at any one time.

Or I could change my modifiers so that they had a "^" on the front if the processor would check that.

Another great option would be to provide a mechanism for extending the url processor. Right now a constant is used to define "path" and that loads the class purl_path, which is not extendible since it uses the purl namespace and a constant which can't be overridden.

CommentFileSizeAuthor
#2 purl_provider_monogamy.patch1.24 KByhahn

Comments

jmiccolis’s picture

Extending processor should now be possible. I've just committed the last batch of work to the DRUPAL-6--1 branch of purl that leverages ctools plugin.inc class loading system. Testing of these changes is very welcome.

However... I'm also thinking that now that the system is pluggable we may want to take that as an opportunity/excuse to bake some more assumptions into the default processors. I think that limiting the path processor to only affect the first part of a path may be a fine one. ...and, in fact, we may already have some pieces of that behavior in place.

yhahn’s picture

Status: Active » Closed (won't fix)
StatusFileSize
new1.24 KB

We won't implement this for the time being, but here's an example patch of how you could implement this in your own processor.