diff options
| author | ben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-04-04 11:01:52 +0000 | 
|---|---|---|
| committer | ben <ben@36083f99-b078-4883-b0ff-0f9b5a30f544> | 2008-04-04 11:01:52 +0000 | 
| commit | 52cac1b8f3d7ead701dbf8d30fddb015cba69f85 (patch) | |
| tree | ae82c9765c0e1ec31b302d9dbd68d6b7c74b73aa /mod/blog/read.php | |
| parent | e5d8c5584d8bad625dc52b08f5556e7f6b06fa77 (diff) | |
| download | elgg-52cac1b8f3d7ead701dbf8d30fddb015cba69f85.tar.gz elgg-52cac1b8f3d7ead701dbf8d30fddb015cba69f85.tar.bz2 | |
Further blog enhancements
git-svn-id: https://code.elgg.org/elgg/trunk@400 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/blog/read.php')
| -rw-r--r-- | mod/blog/read.php | 16 | 
1 files changed, 14 insertions, 2 deletions
| diff --git a/mod/blog/read.php b/mod/blog/read.php index 35ee0c997..84e29d0ea 100644 --- a/mod/blog/read.php +++ b/mod/blog/read.php @@ -14,7 +14,9 @@  		require_once(dirname(dirname(dirname(__FILE__))) . "/engine/start.php");
  	// Get the specified blog post
 -		$post = (int) get_input('blogpost'); 
 +		$post = (int) get_input('blogpost');
 +
 +	// If we can get out the blog post ...
  		if ($blogpost = get_entity($post)) {
  	// Get any comments
 @@ -31,10 +33,20 @@  											'comments' => $comments,
  											'full' => true
  											));
 +											
 +	// Set the title appropriately
 +			$title = sprintf(elgg_echo("blog:posttitle"),$page_owner->name,$blogpost->title);
 +			
 +	// If we're not allowed to see the blog post
 +		} else {
 +			
 +	// Display the 'post not found' page instead
 +			$body = elgg_view("blog/notfound");
 +			$title = elgg_echo("blog:notfound");
  		}
  	// Display page
 -		page_draw(sprintf(elgg_echo("blog:posttitle"),$page_owner->name,$blogpost->title),$body);
 +		page_draw($title,$body);
  ?>
\ No newline at end of file | 
