View Issue Details

IDProjectCategoryView StatusLast Update
0010899mantisbtwikipublic2013-01-18 22:46
Reporterha17 Assigned To 
PrioritynormalSeverityminorReproducibilityalways
Status newResolutionopen 
Product Version1.1.8 
Summary0010899: "Project" wiki passing bad url to MediaWiki engine
Description

If it's a "project" wiki it passes a space/urlencoded URL to the wiki, creating a bad page name for project.

Propose patching core/wiki_mediawiki_api.php

Tagspatch
Attached Files
core_wiki_mediawiki_api.patch (252 bytes)   
38c38
< 		return $t_root_url . 'index.php/' . urlencode( $t_page_id );
---
> 		return $t_root_url . 'index.php/' . $t_page_id;
64c64
< 			return $t_project_name . ':' . $t_home;
---
> 			return ereg_replace ( '[^-/:0-9A-Za-z]', '_', $t_project_name );

Activities

ha17

ha17

2009-09-03 03:00

reporter   ~0022853

Also, if word "Project" is desired, apply this patch after last patch

64c64
< return eregreplace ( '[^-/:0-9A-Za-z]', '', $t_project_name );

      return 'Project_' . ereg_replace ( '[^-/:0-9A-Za-z]', '_', $t_project_name );
grv87

grv87

2013-01-18 22:46

reporter   ~0034824

You should simply use rawurlencode(...) php function instead of urlencode(...).