当前位置: 首页>>代码示例>>PHP>>正文


PHP lms_steam::get_annotation_data方法代码示例

本文整理汇总了PHP中lms_steam::get_annotation_data方法的典型用法代码示例。如果您正苦于以下问题:PHP lms_steam::get_annotation_data方法的具体用法?PHP lms_steam::get_annotation_data怎么用?PHP lms_steam::get_annotation_data使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在lms_steam的用法示例。


在下文中一共展示了lms_steam::get_annotation_data方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: RssChannel

<?php

require_once "../../../etc/koala.conf.php";
require_once PATH_LIB . "format_handling.inc.php";
//lms_steam::connect(); //http_auth function is used instead
require_once PATH_LIB . "http_auth_handling.inc.php";
if (http_auth()) {
    if (!($discussion = steam_factory::get_object($GLOBALS["STEAM"]->get_id(), $_GET["id"]))) {
        include PATH_PUBLIC . "bad_link.php";
        exit;
    }
    $rss_channel = new RssChannel($discussion->get_name(), PATH_URL . "forums/" . $_GET["id"] . "/", "");
    $rss_channel->generate_http_header();
    print $rss_channel->generate_xml_header();
    $object = steam_factory::get_object($GLOBALS["STEAM"]->get_id(), $_GET["id"]);
    if (is_object($object) && !$object instanceof steam_messageboard) {
        $discussion = lms_steam::get_annotation_data($object);
        print $rss_channel->generate_item($discussion["OBJ_NAME"] . " " . gettext("by") . " " . $discussion["OBJ_CREATOR"], "", BBCode($discussion["CONTENT"]), $discussion["OBJ_CREATOR"], $discussion["OBJ_CREATION_TIME"], "", PATH_URL . "forums/" . $_GET["id"] . "/#comment" . $discussion["OBJ_ID"]);
    }
    $cache = get_cache_function($_GET["id"], 600);
    $discussions = $cache->call("lms_steam::get_annotations", $_GET["id"]);
    foreach ($discussions as $discussion) {
        print $rss_channel->generate_item(gettext("Post by ") . $discussion["OBJ_CREATOR"], "", BBCode($discussion["CONTENT"]), $discussion["OBJ_CREATOR"], $discussion["OBJ_CREATION_TIME"], "", PATH_URL . "forums/" . $_GET["id"] . "/#comment" . $discussion["OBJ_ID"]);
    }
    print $rss_channel->generate_xml_footer();
} else {
    $rss_channel = new PodcastRSS("Access denied", PATH_SERVER . $_SERVER["REQUEST_URI"], "You are not allowed to access this RSS Feed. Please check your username and password");
    $rss_channel->generate_http_header();
    $rss_channel->generate_xml_header(TRUE);
    exit;
}
开发者ID:rolwi,项目名称:koala,代码行数:31,代码来源:discussion_public.php


注:本文中的lms_steam::get_annotation_data方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。