function content_view_content
Search API
7.x content.module | content_view_content($cid) |
6.x content.module | content_view_content( |
4.x content.module | content_view_content() |
5.x content.module | content_view_content() |
Display the content specified in the GET's cid.
File
- modules/
content/ content.module, line 207
Code
function content_view_content() {
$rtn = "";
$content = content_load($_GET ["cid"]);
$types = content_get_types();
$author = fp_load_user($content ["user_id"]);
if (!strstr($content ["title"], "[hide]")) {
fp_set_title($content ["title"]);
}
fp_add_body_class("content-type-" . $content ["type"]);
$rtn .= "<div class='content-view content-view-{$content ["type"]}'>";
$rtn .= "<div class='content-submitted'>" . t("Submitted by") . " " . $author->name . " " . t("on");
$rtn .= " " . format_date($content ["posted"]) . "</div>";
$rtn .= "<div class='content-body'>" . $content ["body"] . "</div>";
$rtn .= "</div>";
return $rtn;
}