定制 tkiehne/silverstripe-tumblrfeed 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

tkiehne/silverstripe-tumblrfeed

Composer 安装命令:

composer require tkiehne/silverstripe-tumblrfeed

包简介

Tumblr API module for SilverStripe.

README 文档

README

Silverstripe module to load Tumblr feeds via Tumblr API V2

Maintainer Contact

Requirements

  • Silverstripe 3.x

Installation

    $ composer require tkiehne/silverstripe-tumblrfeed

Usage

  • Add to your mysite/_config/config.yml to extend the object of your choice:
    Page:
        extensions:
            - TumblrPageExtension

or set the following call in mysite/_config.php:

    Page::add_extension('TumblrPageExtension');
  • Build and flush using /dev/build/?flush=1
  • Add Tumblr API keys and blog name via Admin > Settings > Tumblr tab (Register your application to get your API keys)
  • Place and Include call in your template (see below for options), e.g.:
    <% include TumblrPosts Posts=$TumblrPostsList %>

Call Methods and Options

All Posts

    TumblrPostsList($limit, $offset, $type, $options)

Proxy Methods for Specific Post Types

    TumblrTextPostsList($limit, $offset, $tag, $text)
    
    TumblrQuotePostsList($limit, $offset, $tag, $text)
    
    TumblrLinkPostsList($limit, $offset, $tag, $text)
    
    TumblrAnswerPostsList($limit, $offset, $tag, $text)
    
    TumblrVideoPostsList($limit, $offset, $tag, $text)
    
    TumblrAudioPostsList($limit, $offset, $tag, $text)
    
    TumblrPhotoPostsList($limit, $offset, $tag, $text)
    
    TumblrChatPostsList($limit, $offset, $tag, $text)

Single Post by ID

    TumblrPost($id, $text)

Options

  • limit = number of posts to show, from 1 to 20 (API max limit)
  • offset = number of posts to skip
  • type = name of post type to retrieve (see below)
  • options = array of API options
  • tag = name of a tag to filter by (single tag only)
  • text = boolean flag; return plain text (true) or html markup (false, default) in text fields
  • id = numeric Tumblr post ID

Templates

By default, the TumblrPosts.ss include will call subsequent includes depending on post type. To customize the list container, override or create a copy of TumblrPosts. To customize the way that posts are displayed within the container, override the respective Tumblr[TYPE]Post.ss or, if you've customized the container, create your own include.

Include variables follow the syntax and structure of the Tumblr API, based on the "posts" collection of the response. See the module's default includes for examples and be aware of template context.

Caching

This module uses SS_Cache to reduce the amount of API requests. Default cache lifetime is 30 minutes. You can change this value by putting this line in your _config.php (1800 is cache lifetime in seconds):

SS_Cache::set_cache_lifetime('tumblr_api_cache', 1800, 10);

Dependencies

Uses the official Tumblr API v2 PHP Client

tkiehne/silverstripe-tumblrfeed 适用场景与选型建议

tkiehne/silverstripe-tumblrfeed 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 9 次下载、GitHub Stars 达 0, 最近一次更新时间为 2016 年 06 月 01 日, 在 PHP 生态内属于活跃度较高的组件。

它主要适用于以下技术方向: 「silverstripe」 「tumblr」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。

我们在过去多个企业项目中使用过 tkiehne/silverstripe-tumblrfeed 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 tkiehne/silverstripe-tumblrfeed 我们能提供哪些服务?
定制开发 / 二次开发

基于 tkiehne/silverstripe-tumblrfeed 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 9
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 0
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 1
  • Forks: 1
  • 开发语言: PHP

其他信息

  • 授权协议: CC0
  • 更新时间: 2016-06-01