]> CyberLeo.Net >> Repos - SourceForge/phpwiki.git/blob - themes/default/templates/wikiblog.tmpl
renamed global $Theme to $WikiTheme (gforge nameclash)
[SourceForge/phpwiki.git] / themes / default / templates / wikiblog.tmpl
1 <!-- $Id: wikiblog.tmpl,v 1.3 2004-06-14 11:26:53 rurban Exp $ -->
2 <?php
3 $CDATE = $WikiTheme->formatDateTime($BLOG_CTIME);
4
5 $buttons = $modified = '';
6
7 if ($user->isAdmin() or $user->getId() == $BLOG_CREATOR) {
8     $buttons = HTML::small(array('class' => 'floatleft'),
9                            Button('edit', false, $page));
10     if ($user->isAdmin())
11       $buttons->pushContent(Button('remove', false, $page));
12 }
13
14 // This is a hack, but since we only have a fake PageRevision,
15 // we can't get the version.
16 if ($rev->get('mtime') != $BLOG_CTIME) {
17     $mtime = $WikiTheme->formatDateTime($rev->get('mtime'));
18     $modified = HTML::small(array('class' => 'floatright'),
19                             fmt("Comment modified on %s by %s",
20                                 $mtime, $rev->get('author')));
21 }
22 ?>
23
24 <!-- FIXME: move table formatting to css -->
25 <div title="<?= fmt("Comments on %s by %s.", $BLOG_PARENT, $BLOG_CREATOR)?>"
26      class="wikiblog wikitext">
27   <div class="wikiblog-header">
28     <strong class="floatleft"><?= WikiLink($page, 'known', $CDATE) ?></strong>
29     <strong class="floatright"><?= WikiLink($BLOG_CREATOR, 'if_known') ?></strong>
30     <br clear="all" class="clear-floats" />
31   </div>
32   <div class="wikiblog-body">
33     <?php if ($rev->get('summary')) { ?> 
34       <h3 class="wikiblog-summary"><?= $rev->get('summary') ?></h3>
35     <?php } ?>  
36     <?= $CONTENT ?>
37   </div>
38
39   <?php if ($buttons or $modified) { ?>
40     <div class="wikiblog-footer">
41       <?= $buttons ?>
42       <?= $modified ?>
43       <br clear="all" class="clear-floats" />
44     </div>
45   <?php } ?>
46
47 </div>
48 <hr class="no-css" />