summaryrefslogtreecommitdiff
path: root/lib/noticelist.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@controlyourself.ca>2009-06-09 21:51:24 -0700
committerEvan Prodromou <evan@controlyourself.ca>2009-06-09 21:51:24 -0700
commit4df1ea49ec75ec9dd64bc8f58c01e64ea18bedc7 (patch)
tree91535b33cd2b62b0726821e4d217d587da7cd61b /lib/noticelist.php
parentb3628b78448266fda2368f1317e70d1cca45ac17 (diff)
parented627bb4bd6424325478412055d295b185f9f662 (diff)
Merge branch '0.8.x' into userdesign
Conflicts: actions/designsettings.php
Diffstat (limited to 'lib/noticelist.php')
-rw-r--r--lib/noticelist.php15
1 files changed, 13 insertions, 2 deletions
diff --git a/lib/noticelist.php b/lib/noticelist.php
index 8aab83433..c00942af4 100644
--- a/lib/noticelist.php
+++ b/lib/noticelist.php
@@ -85,7 +85,7 @@ class NoticeList extends Widget
{
$this->out->elementStart('div', array('id' =>'notices_primary'));
$this->out->element('h2', null, _('Notices'));
- $this->out->elementStart('ul', array('class' => 'notices'));
+ $this->out->elementStart('ol', array('class' => 'notices xoxo'));
$cnt = 0;
@@ -100,7 +100,7 @@ class NoticeList extends Widget
$item->show();
}
- $this->out->elementEnd('ul');
+ $this->out->elementEnd('ol');
$this->out->elementEnd('div');
return $cnt;
@@ -205,6 +205,7 @@ class NoticeListItem extends Widget
return 'shownotice' !== $this->out->args['action'];
}
+/*
function attachmentCount($discriminant = true) {
$file_oembed = new File_oembed;
$query = "select count(*) as c from file_oembed join file_to_post on file_oembed.file_id = file_to_post.file_id where post_id=" . $this->notice->id;
@@ -212,11 +213,16 @@ class NoticeListItem extends Widget
$file_oembed->fetch();
return intval($file_oembed->c);
}
+*/
+
+ function showWithAttachment() {
+ }
function showNoticeInfo()
{
$this->out->elementStart('div', 'entry-content');
$this->showNoticeLink();
+// $this->showWithAttachment();
$this->showNoticeSource();
$this->showContext();
$this->out->elementEnd('div');
@@ -357,6 +363,10 @@ class NoticeListItem extends Widget
// versions (>> 0.4.x)
$this->out->raw(common_render_content($this->notice->content, $this->notice));
}
+ $uploaded = $this->notice->getUploadedAttachment();
+ if ($uploaded) {
+ $this->out->element('a', array('href' => $uploaded, 'class' => 'attachment'), $uploaded);
+ }
$this->out->elementEnd('p');
}
@@ -387,6 +397,7 @@ class NoticeListItem extends Widget
$this->out->element('abbr', array('class' => 'published',
'title' => $dt),
common_date_string($this->notice->created));
+
$this->out->elementEnd('a');
$this->out->elementEnd('dd');
$this->out->elementEnd('dl');