Skip to content

Commit

Permalink
Fix for #721 preg_match was not allowing for .
Browse files Browse the repository at this point in the history
  • Loading branch information
Kilandor committed Oct 11, 2011
1 parent 066c884 commit ab72328
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions plugins/urleditor/inc/urleditor.functions.php
Expand Up @@ -20,12 +20,12 @@
function cot_apply_rwr()
{
global $cfg, $structure;
if (isset($_GET['rwr']) && !empty($_GET['rwr']) && preg_match('`^[\w\p{L}/\-_\ \+]+?$`u', $_GET['rwr']))
if (isset($_GET['rwr']) && !empty($_GET['rwr']) && preg_match('`^[\w\p{L}/\-_\ \+\.]+?$`u', $_GET['rwr']))
{
// Ignore ending slash and split the path into parts
$path = explode('/', (mb_strrpos($_GET['rwr'], '/') == mb_strlen($_GET['rwr']) - 1) ? mb_substr($_GET['rwr'], 0, -1) : $_GET['rwr']);
$count = count($path);

print_r($path);
if ($count == 1)
{
if (isset($structure['page'][$path[0]]))
Expand Down Expand Up @@ -83,6 +83,7 @@ function cot_apply_rwr()
}
}
}
echo "WHAT?";
}

/**
Expand Down

0 comments on commit ab72328

Please sign in to comment.