Drupal Association members fund grants that make connections all over the world.
I was trying to write my own dynamic tokens just like the [date:custom:?] token and noticed that the tokens can't have spaces in them. In the token_scan() function it does say that both the type and token can't have spaces in it and the regexp clearly indicates that too.
I guess I'm a bit confused on how it is supposed to operate. It seems like the [date:custom:?] token takes arguments or parameters but really that is not the case at all. It just means the actual name of the token after "custom" can be dynamic.
If you try and use this token [date:custom:Y m] it will not work because there is a space in it. If you use [date:custom:Y-m] it works fine.
I'm not sure what the ramifications are in having tokens that can have spaces but I've attached a patch here that does allow spaces in tokens.
If tokens should not have spaces in them is there a better way to have a token like interface that allows parameters? I suppose one could make a custom filter but it just seems redundant to me.
FAILED: [[SimpleTest]]: [MySQL] 39,928 pass(es), 1 fail(s), and 0 exception(s). View
PASSED: [[SimpleTest]]: [MySQL] 39,940 pass(es). View
PASSED: [[SimpleTest]]: [MySQL] 39,824 pass(es). View
FAILED: [[SimpleTest]]: [MySQL] Failed to run tests: failed during invocation of run-tests.sh. View