diff options
Diffstat (limited to 'engine')
-rw-r--r-- | engine/lib/elgglib.php | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/engine/lib/elgglib.php b/engine/lib/elgglib.php index 392f6cd8b..cf3bea742 100644 --- a/engine/lib/elgglib.php +++ b/engine/lib/elgglib.php @@ -37,6 +37,13 @@ $location = $CONFIG->url . $location; } + // Preserve current viewtype + $viewtype = elgg_get_viewtype(); + if (($viewtype) && (strcmp($viewtype, 'default')!=0)) { + $sep = "?"; + if (strpos($location, '?')>0) $sep = "&"; + $location .= "{$sep}view=$viewtype"; + } header("Location: {$location}"); exit; |