承接 amireshoon/luna 相关项目开发

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

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

amireshoon/luna

Composer 安装命令:

composer require amireshoon/luna

包简介

Luna is a simple very light class to render HTML pages or views or any file in PHP

README 文档

README

Luna is a simple very light class to render HTML pages or views in PHP

Instalation

You can install via composer or direclty copy the class or clone repo.

composer require amireshoon/luna

Content format

You can render HTML pages or view or any context of any kind of file. You just have to include your keyword like this:

This is my {message} for you dear {name}.

or in html format your content should be like this:

<!DOCTYPE html>
<html>
  <head>
    <title>{title}</title>
  </head>
  <body>

    <h1>This is my {message} for you dear <code>{name}</code></h1>

  </body>
</html>

Usage

It's simple just give luna the file and variables, That's it.

You can get rendered output by two methods, You can directly print on-screen, or luna will be return rendered content to you.

render() function takes one argument that is output type. By setting it true you will get renderer out put and you can use it however you want to, And if you set that false rendered content will be direclty print on screen. Anyways it's optional default is true.

$luna->page( __DIR__ . '/mypage.html')
     ->with([
        'title'   => 'My very first page',
        'message' => 'Hello world',
        'name'    => 'Gophy',
     ])
     ->render(false);

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2021-07-21

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固