Commit db93312b authored by Dries's avatar Dries
Browse files

- Patch #285165 by Heine, Gabor: fixed wildcard loader names with numbers.

parent 2dd6e4e0
......@@ -2276,7 +2276,10 @@ function _menu_router_build($callbacks) {
// Extract load and to_arg functions.
foreach ($parts as $k => $part) {
$match = FALSE;
if (preg_match('/^%([a-z_]*)$/', $part, $matches)) {
// Look for wildcards in the form allowed to be used in PHP functions,
// because we are using these to construct the load function names.
// See http://php.net/manual/en/language.functions.php for reference.
if (preg_match('/^%([a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*)$/', $part, $matches)) {
if (empty($matches[1])) {
$match = TRUE;
$load_functions[$k] = NULL;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment