承接 hashchange/slim-legacy-mustache 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

hashchange/slim-legacy-mustache

Composer 安装命令:

composer require hashchange/slim-legacy-mustache

包简介

Mustache support for Slim 1.x, backward compatible with PHP 5.2

README 文档

README

Slim is a micro PHP 5 framework that helps you quickly write simple yet powerful RESTful web applications. Its 1.x branch is backward compatible with PHP 5.2.

This repository contains a custom Mustache view for Slim 1.x, offering full support for Mustache.php.

Where it differs from the "official" repo

Mustache support for Slim is provided by a single class. It is based on the Mustache view contained in Slim-Extras, but is customized in a number of ways.

Functional differences:

  • This version of the class is compatible with PHP 5.2 and does not use namespaces.
  • The class allows an object to be used as view data, thus enabling the use of Mustache lambdas in PHP 5.2. The version in the official repo only supports arrays.

Implementation details:

  • The class requires Slim 1.x and won't work with Slim 2.x (use Slim-Extras for that). It extends Slim_View, not \Slim\View.
  • The class is called View_Mustache, not Mustache. It has been renamed to avoid conflicts in the absence of namespaces.

Otherwise, it is used in the exact same way as the class provided with Slim-Extras. See there for usage notes.

Installation

Slim-Legacy-Mustache is best installed with Composer and is available from Packagist as "hashchange/slim-legacy-mustache".

The following setup in composer.json will install Slim and Mustache for PHP 5.2 in one go:

{
    "require": {
        "slim/slim": "1.*",
        "hashchange/slim-legacy-mustache": "*",
        "mustache/mustache": "2.*"
    }
}

Version

The current version is based on Mustache.php @ b12fdd0 in Slim-Extras 2.0.3-develop, last updated on 19 Jan 2013. It was tested with Slim 1.6.7.

Related

Slim

Primary Slim repo
Primary Slim-Extras repo
Slim website

Mustache

Primary Mustache.php repo
Mustache.php wiki
Mustache website

Open Source License

The resources in this repository are released under the MIT public license.

http://www.slimframework.com/license

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2013-04-02

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固