aboutsummaryrefslogtreecommitdiff
path: root/index.php
diff options
context:
space:
mode:
Diffstat (limited to 'index.php')
-rw-r--r--index.php30
1 files changed, 9 insertions, 21 deletions
diff --git a/index.php b/index.php
index 00b09d14b..32c389e2e 100644
--- a/index.php
+++ b/index.php
@@ -2,17 +2,10 @@
/**
* Elgg tidypics photo gallery main page
*
- * @package ElggFile
- * @author Curverider Ltd
- * @copyright Curverider Ltd 2008
- * @link http://elgg.com/
- *
- *
*
*/
- //require_once(dirname(dirname(dirname(__FILE__))) . "/engine/start.php");
- require_once(dirname(dirname(dirname(__FILE__))) . "/engine/start.php");
+ include_once(dirname(dirname(dirname(__FILE__))) . "/engine/start.php");
//get the owner of the current page
$owner = page_owner_entity();
@@ -25,21 +18,16 @@
}
//set the title
- $area2 = elgg_view_title($title = sprintf(elgg_echo('album:user'), "$owner->name"));
-
- //allow new album creation
- if(can_write_to_container($_SESSION['guid'], page_owner())){
- $area2 .= '<a href="'.$CONFIG->wwwroot . "pg/photos/new/". $owner->username.'">'.elgg_echo('album:create').'</a><br><br>';
- }
-
+ $area2 = elgg_view_title($title = sprintf(elgg_echo('album:user'), "$owner->name"));
+
// Get objects
- set_context('search');
- set_input('search_viewtype', 'gallery');
- $area2 .= list_entities("object","album",page_owner(),10);
+ set_context('search');
+ set_input('search_viewtype', 'gallery');
+ $area2 .= list_entities("object","album",page_owner(),10);
- set_context('photos');
- $body = elgg_view_layout('two_column_left_sidebar', '', $area2);
+ set_context('photos');
+ $body = elgg_view_layout('two_column_left_sidebar', '', $area2);
// Finally draw the page
- page_draw(sprintf(elgg_echo("album:user"),page_owner_entity()->name), $body);
+ page_draw(sprintf(elgg_echo("album:user"),page_owner_entity()->name), $body);
?> \ No newline at end of file