cid : $page->cid; if ($cid) { \Typecho\Widget::widget('Widget_Contents_Attachment_Related', 'parentId=' . $cid)->to($attachment); } else { \Typecho\Widget::widget('Widget_Contents_Attachment_Unattached')->to($attachment); } } ?>