定制 gnugat/carew-next 二次开发

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

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

gnugat/carew-next

最新稳定版本:v1.0.0

Composer 安装命令:

composer require gnugat/carew-next

包简介

Plugin for carew, add next_document and previous_document functions

关键字:

README 文档

README

This Carew plugin adds two new functions:

  • next_document()
  • previous_document()

With these, you'll be able to automatically have links pointing to the next and previous pages:

{% block content_main %}
    {{ carew.document.body|raw }}

    <ul>
        {% set next = next_document(carew.posts, carew.document) %}
        {% if next %}
        <li>Next: <a href="{{ render_document_path(next) }}">{{ next.title }}</a></li>
        {% endif %}

        {% set previous = previous_document(carew.posts, carew.document) %}
        {% if previous %}
        <li>Previous: <a href="{{ render_document_path(previous) }}">{{ previous.title }}</a></li>
        {% endif %}
    <ul>
{% endblock %}

Installation

Use Composer:

composer require "gnugat/carew-next:~1.0"

Then register the plugin:

engine:
    extensions:
        - Gnugat\CarewNext\NextExtension

Further documentation

You can see the current and past versions using one of the following:

You can find more documentation at the following links:

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-04-10