aboutsummaryrefslogtreecommitdiff
path: root/mod/bookmarks/views/default/object
diff options
context:
space:
mode:
authorcash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-10-20 23:46:46 +0000
committercash <cash@36083f99-b078-4883-b0ff-0f9b5a30f544>2010-10-20 23:46:46 +0000
commitc3332e10712c0ec7f3540e54c794fa4dae3532f9 (patch)
tree900952540757a2ee85ce71b291095cf8d65a7891 /mod/bookmarks/views/default/object
parent7bbb0ca2fb7e205074a9009f7604cb2c289cca73 (diff)
downloadelgg-c3332e10712c0ec7f3540e54c794fa4dae3532f9.tar.gz
elgg-c3332e10712c0ec7f3540e54c794fa4dae3532f9.tar.bz2
Refs #2551 - merged [7051] and [7053] into trunk
git-svn-id: http://code.elgg.org/elgg/trunk@7112 36083f99-b078-4883-b0ff-0f9b5a30f544
Diffstat (limited to 'mod/bookmarks/views/default/object')
-rw-r--r--mod/bookmarks/views/default/object/bookmarks.php14
1 files changed, 11 insertions, 3 deletions
diff --git a/mod/bookmarks/views/default/object/bookmarks.php b/mod/bookmarks/views/default/object/bookmarks.php
index 67ba1bd91..4dcb53605 100644
--- a/mod/bookmarks/views/default/object/bookmarks.php
+++ b/mod/bookmarks/views/default/object/bookmarks.php
@@ -11,7 +11,15 @@
$owner = $vars['entity']->getOwnerEntity();
$friendlytime = elgg_view_friendly_time($vars['entity']->time_created);
-$parsed_url = parse_url($vars['entity']->address);
+$address = $vars['entity']->address;
+
+// you used to be able to add without titles, which created unclickable bookmarks
+// putting a fake title in so you can click on it.
+if (!$title = $vars['entity']->title) {
+ $title = elgg_echo('bookmarks:no_title');
+}
+
+$parsed_url = parse_url($address);
$faviconurl = $parsed_url['scheme'] . "://" . $parsed_url['host'] . "/favicon.ico";
//sort out the access level for display
@@ -51,7 +59,7 @@ if (@file_exists($faviconurl)) {
//delete
if($vars['entity']->canEdit()){
-$delete .= "<span class='delete_button'>" . elgg_view('output/confirmlink',array(
+ $delete .= "<span class='delete_button'>" . elgg_view('output/confirmlink',array(
'href' => $vars['url'] . "action/bookmarks/delete?bookmark_guid=" . $vars['entity']->guid,
'text' => elgg_echo("delete"),
'confirm' => elgg_echo("bookmarks:delete:confirm"),
@@ -72,7 +80,7 @@ if($vars['entity']->canEdit()){
$info .= "</div>";
-$info .= "<p class='entity_title'><a href=\"{$vars['entity']->address}\" target=\"_blank\">{$vars['entity']->title}</a></p>";
+$info .= "<p class='entity_title'><a href=\"{$address}\" target=\"_blank\">{$title}</a></p>";
$info .= "<p class='entity_subtext'>Bookmarked by <a href=\"{$vars['url']}pg/bookmarks/{$owner->username}\">{$owner->name}</a> {$friendlytime} {$view_notes}</p>";
$tags = elgg_view('output/tags', array('tags' => $vars['entity']->tags));