# HG changeset patch # User Dan # Date 1200931516 18000 # Node ID 35ed07abc99e1abab6d05e2855a5d901b107e7ae # Parent fad9bb5c094b4f379df0caf941ace684be46ea17 PageUtils::createpage(): $name was being sanitized too strictly diff -r fad9bb5c094b -r 35ed07abc99e includes/pageutils.php --- a/includes/pageutils.php Mon Jan 21 10:17:26 2008 -0500 +++ b/includes/pageutils.php Mon Jan 21 11:05:16 2008 -0500 @@ -439,16 +439,20 @@ return 'The prefix "Project:" is reserved for a parser shortcut; if a page was created using this prefix, it would not be possible to link to it.'; } - $page_id = dirtify_page_id($page_id); - - if ( !$name ) - $name = str_replace('_', ' ', $page_id); + /* + // Dunno why this was here. Enano can handle more flexible names than this... $regex = '#^([A-z0-9 _\-\.\/\!\@\(\)]*)$#is'; if(!preg_match($regex, $name)) { //echo 'Notice: PageUtils::createPage: Name contains invalid characters
'; return 'Name contains invalid characters'; } + */ + + $page_id = dirtify_page_id($page_id); + + if ( !$name ) + $name = str_replace('_', ' ', $page_id); $page_id = sanitize_page_id( $page_id );