aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--languages/en.php2
-rw-r--r--mod/pages/pages/pages/edit.php6
2 files changed, 6 insertions, 2 deletions
diff --git a/languages/en.php b/languages/en.php
index 6aa292e5a..62effb334 100644
--- a/languages/en.php
+++ b/languages/en.php
@@ -237,6 +237,8 @@ $english = array(
'pageownerunavailable' => 'Warning: The page owner %d is not accessible!',
'viewfailure' => 'There was an internal failure in the view %s',
'changebookmark' => 'Please change your bookmark for this page',
+ 'noaccess' => 'This content has been removed, is invalid, or you do not have permission to view it.',
+
/**
* API
*/
diff --git a/mod/pages/pages/pages/edit.php b/mod/pages/pages/pages/edit.php
index 6f54d72bf..1f411b94d 100644
--- a/mod/pages/pages/pages/edit.php
+++ b/mod/pages/pages/pages/edit.php
@@ -10,12 +10,14 @@ gatekeeper();
$page_guid = (int)get_input('guid');
$page = get_entity($page_guid);
if (!$page) {
-
+ register_error(elgg_echo('noaccess'));
+ forward('');
}
$container = $page->getContainerEntity();
if (!$container) {
-
+ register_error(elgg_echo('noaccess'));
+ forward('');
}
elgg_set_page_owner_guid($container->getGUID());