t("Author")); } static function get($block_id, $theme) { $block = ""; $item = $theme->item; if ((!isset($theme->item)) || ($item->is_album())) { return; } switch ($block_id) { case "author": $record = ORM::factory("author_record")->where("item_id", "=", $item->id)->find(); $byline = ""; if ($record->loaded()) { $byline = $record->author; } if ($byline == '') { $byline = author::fix($item); } $block = new Block(); $block->css_id = "g-author"; $block->content = new View("author_block.html"); $block->content->author = $byline; break; } return $block; } }