anomaly/pages-module 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

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

anomaly/pages-module

最新稳定版本:v2.7.2

Composer 安装命令:

composer require anomaly/pages-module

包简介

Create pages, generate navigation, manage content, and build websites faster than ever.

README 文档

README

anomaly.module.pages

Create pages, generate navigation, manage content, and build websites faster than ever.

The Pages Module is PyroCMS's flagship content management system for building dynamic websites with powerful page types and layouts.

Features

  • Page type system
  • Layout management
  • Nested page structure
  • Route handling
  • SEO optimization
  • Multiple page types
  • Template variables
  • Page drafts & versioning

Usage

Creating Page Types

Navigate to Pages > Types in the control panel to create page types with custom fields and layouts.

Accessing Pages

use Anomaly\PagesModule\Page\Contract\PageRepositoryInterface;

$pages = app(PageRepositoryInterface::class);

// Get page by path
$page = $pages->findByPath('/about');

// Get home page
$home = $pages->findHome();

// Get child pages
$children = $pages->findChildren($page);

In Twig

{# Current page #}
{{ page.title }}
{{ page.meta_title }}
{{ page.content|raw }}

{# Navigation #}
{% for child in page.children %}
    <a href="{{ child.path }}">{{ child.title }}</a>
{% endfor %}

{# Build menu from pages #}
{% for item in pages().root().get() %}
    <a href="{{ item.path }}">{{ item.title }}</a>
{% endfor %}

Page Variables

{# Access page type fields #}
{{ page.content }}
{{ page.hero_image.path }}
{{ page.gallery.images }}

{# Meta information #}
<title>{{ page.meta_title }}</title>
<meta name="description" content="{{ page.meta_description }}">

Requirements

  • Streams Platform ^1.10
  • PyroCMS 3.10+
  • Preferences Module ^2.3+

License

The Pages Module is open-sourced software licensed under the MIT license.

统计信息

  • 总下载量: 46.64k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 8
  • 点击次数: 3
  • 依赖项目数: 2
  • 推荐数: 0

GitHub 信息

  • Stars: 8
  • Watchers: 2
  • Forks: 22
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-03-07

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固