Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Backporting MDL-15896 (tabs and recent activity) from HEAD

  • Loading branch information...
commit 7b8a8bc587bf5c4f81eaf3c0d12dc2d918a341c7 1 parent cb46a96
stronk7 authored
Showing with 5 additions and 1 deletion.
  1. +4 −0 mod/wiki/lib.php
  2. +1 −1  mod/wiki/view.php
View
4 mod/wiki/lib.php
@@ -157,6 +157,10 @@ function wiki_print_recent_activity($course, $isteacher, $timestart) {
//Obtain the visible property from the instance
$modvisible = instance_is_visible($log->module,$tempmod);
+ /// Process log->url and rebuild it here to properly clean the pagename - MDL-15896
+ $extractedpage = preg_replace('/^.*&page=/', '', $log->url);
+ $log->url = preg_replace('/page=.*$/', 'page='.urlencode($extractedpage), $log->url);
+
//Only if the mod is visible
if ($modvisible) {
$wikis[$log->info] = wiki_log_info($log);
View
2  mod/wiki/view.php
@@ -327,7 +327,7 @@
$currenttab = '';
foreach ($tabs as $tab) {
$tabname = get_string("tab$tab", 'wiki');
- $row[] = new tabobject($tabname, $ewbase.'&page='.$tab.'/'.$ewiki_id, $tabname);
+ $row[] = new tabobject($tabname, $ewbase.'&page='.$tab.'/'.s($ewiki_id), $tabname);
if ($ewiki_action == "$tab" or in_array($page, $specialpages)) {
$currenttab = $tabname;
}
Please sign in to comment.
Something went wrong with that request. Please try again.