Permalink
Browse files

Rendering NotReblog block and inserting one localization string example

  • Loading branch information...
1 parent 219cd3e commit a49c5d26a1ade5fc63d20d7d9b0bf33be7a1ad3a @mwunsch mwunsch committed Sep 20, 2010
Showing with 7 additions and 1 deletion.
  1. +7 −1 parser/parser.php
View
@@ -396,7 +396,9 @@ public function prepare_post($post, $markup) {
if ($post['Reblog']) {
$block = $this->render_reblog_info($post, $block);
- }
+ } else {
+ $block = $this->render_block('NotReblog', $block);
+ }
$block = $this->render_block('More', $block);
return $block;
@@ -454,6 +456,10 @@ protected function render_post_date($post, $block) {
$html = $this->render_variable('Minutes', strftime('%M',$time), $html);
$html = $this->render_variable('Seconds', strftime('%S',$time), $html);
+ if ($post['Reblog']) {
+ $html = $this->render_locale_string('Reblogged TimeAgo from ReblogParentName',$html, $day_difference." days ago", $post['Reblog']['ReblogParentName']);
+ }
+
$html = $this->render_block('Date', $html);
return $html;
}

0 comments on commit a49c5d2

Please sign in to comment.