First of all: Very good module.
I have one problem with rules. I have set up a rule when book page is updated an alert should be set. It works. But I have an URL alias for my book pages e.g.
http://at.test.com/magazin-titelseite/reisemagazin/betreutes-reisen-durc...
in the rule I tried the following tokens:
and
the result is:
http://at.test.com/magazin/reisemagazin/Betreutes%20Reisen%20durch%20das...(Oberösterreich,%20Vorarlberg)
which is different from the URL alias e.g.
Capital Letters: Betreutes vs. betreutes
and - character: betreutes-reisen vs. Betreutes%20Reisen
Comments
Comment #1
baff commentedCopy and paste was no good idea, here again the tokens
[node:bookpath]
[node:bookpathalias]
Comment #2
baff commentedIt has nothing to to with book tokens - the problem exists for all Url Aliases (pathauto module)
Comment #3
baff commentedComment #4
icecreamyou commentedI don't know why this was posted in the Appbar queue. Appbar doesn't have anything to do with tokens or aliases.
Comment #5
gregglesI guess this is really about Rules?
The tokens you mention are not the style of tokens that Pathauto uses afaik.
Comment #6
baff commentedOK I understand now. Thanks!
Comment #7
tnanek commentedThis is definitly an issue with Rules. Pathauto handles punctuation (including spaces) just fine according to its settings. Rules just hasn't applied those settings to its aliases.
When generating aliases, I believe Rules should check if Pathauto is installed, and if so, try to make use of its settings, since they are extensive, and already in existence. If not, just use the default to not necessitate the dependency (Rules clearly has more applications than paths, so why require that).
And this is still present in Rules 7.x-2.0 at the very least.
I may get around to patching this over the coming weekend latest, since it's functionality I need; will update this issue if that is done.
Comment #8
tnanek commentedOkay, on checking out api's, integration with Rules seems to commonly be put on the other module.
* To see the similar issues, take a look at the Rules integration tagged issues, see that most are not with Rules specifically.
* To see the api functions for implementation, see the rules api on drupalcode.org
* I'm not precisely sure where the change needs to happen, but as a start, here is the path module's implementation within rules.
I may work on this further as well, but I believe this is accurately categorized now.
Comment #9
tnanek commentedAdding the aforementioned tag.
Comment #10
dave reidThere's nothing really for Pathauto to do here though. I'm not sure what feature this is actually requesting? It made more sense for Rules to use Pathauto's cleanstring functions if available when setting URLs for things in Rules.
Comment #11
tnanek commentedSorry for the misassaigned issue tags prior.
On looking at the source of rules, more particularly at where the path module is evaluated (to be applied), I found a relevant @todo, in order to apply a variable for taking the place of spaces; once this todo is done, it will use a custom function to clean up the alias (see rules_clean_path() in the file linked to above).
Meanwhile, I don't see why not to make use of pathauto in the default application, thus I'm working on a patch for that at the moment. Likely the best place to make use of it is just after tokens are substituted, before that is merged with the full path; I just have to locate where that is and it will be done quickly.
Comment #12
tnanek commentedUpdating status.
Comment #13
fagoYep, that's planned for a long time. Let's do it - see #403170: Add ctools, pathauto rules path cleaning callbacks and settings.
Comment #14
mitchell commentedUpdated component.