aboutsummaryrefslogtreecommitdiff
path: root/mod/blog/views
diff options
context:
space:
mode:
Diffstat (limited to 'mod/blog/views')
-rw-r--r--mod/blog/views/default/blog/sidebar/archives.php9
-rw-r--r--mod/blog/views/default/forms/blog/save.php4
2 files changed, 8 insertions, 5 deletions
diff --git a/mod/blog/views/default/blog/sidebar/archives.php b/mod/blog/views/default/blog/sidebar/archives.php
index 3d8f28ca4..030261094 100644
--- a/mod/blog/views/default/blog/sidebar/archives.php
+++ b/mod/blog/views/default/blog/sidebar/archives.php
@@ -3,9 +3,12 @@
* Blog archives
*/
-$loggedin_user = elgg_get_logged_in_user_entity();
$page_owner = elgg_get_page_owner_entity();
+if (!$page_owner) {
+ return true;
+}
+
if (elgg_instanceof($page_owner, 'user')) {
$url_segment = 'blog/archive/' . $page_owner->username;
} else {
@@ -15,7 +18,7 @@ if (elgg_instanceof($page_owner, 'user')) {
// This is a limitation of the URL schema.
if ($page_owner && $vars['page'] != 'friends') {
$dates = get_entity_dates('object', 'blog', $page_owner->getGUID());
-
+
if ($dates) {
$title = elgg_echo('blog:archives');
$content = '<ul class="blog-archives">';
@@ -31,4 +34,4 @@ if ($page_owner && $vars['page'] != 'friends') {
echo elgg_view_module('aside', $title, $content);
}
-} \ No newline at end of file
+}
diff --git a/mod/blog/views/default/forms/blog/save.php b/mod/blog/views/default/forms/blog/save.php
index 0aefae0d9..36fa2e0e8 100644
--- a/mod/blog/views/default/forms/blog/save.php
+++ b/mod/blog/views/default/forms/blog/save.php
@@ -23,7 +23,7 @@ if ($vars['guid']) {
$delete_link = elgg_view('output/confirmlink', array(
'href' => $delete_url,
'text' => elgg_echo('delete'),
- 'class' => 'elgg-button elgg-button-delete elgg-state-disabled float-alt'
+ 'class' => 'elgg-button elgg-button-delete float-alt'
));
}
@@ -53,7 +53,7 @@ $excerpt_label = elgg_echo('blog:excerpt');
$excerpt_input = elgg_view('input/text', array(
'name' => 'excerpt',
'id' => 'blog_excerpt',
- 'value' => html_entity_decode($vars['excerpt'], ENT_COMPAT, 'UTF-8')
+ 'value' => _elgg_html_decode($vars['excerpt'])
));
$body_label = elgg_echo('blog:body');