定制 bvanhoekelen/terminal-style 二次开发

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

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

bvanhoekelen/terminal-style

最新稳定版本:v1.0.5

Composer 安装命令:

composer require bvanhoekelen/terminal-style

包简介

Return your terminal message in style! Change the text style, text color and text background color form the terminal interface with ANSI color codes. The terminal style tool support Laravel and Composer.

README 文档

README

Hex.pm GitHub release Packagist Github issues

Highlight

How to use

 echo terminal_style($message = null, $color = null, $background = null, $style = null);

Text color

PHP Terminal style set text color

Code example

// Print red text 
echo terminal_style('Here your text', 'red');

Text color names

Use can use: default, yellow, red, green, light-gray ...

See the full color name list here

Background color

PHP Terminal style set background color

Code example

// Print text with background red
echo terminal_style('Here your text', null, 'red');

Background colors names

Use can use: default, yellow, red, green, light-gray ...

See the full background color name list here or see custom background color

Text style

PHP Terminal style set style

Code example

// Print text style bold
echo terminal_style('Here your text', null, null, 'bold');

Text styles

Use can use: default, bold , dim, italic, underlined, 'blink' ...

See the full text style name list here

Help, docs and links

Backlog & Feedback

If you have any suggestions to improve this php terminal style tool? Please add your feature, bug or improvement to the BACKLOG.dm. Or create a issues.

Installation

Install with Laravel

Get PHP terminal style tool by running the Composer command in the command line.

 $ composer require bvanhoekelen/terminal-style

Open your file and use terminal_style()

// Print red text 
echo terminal_style('Here your text', 'red');

Install with composer

Get PHP terminal style tool by running the Composer command in the command line.

 $ composer require bvanhoekelen/terminal-style

Open your file and use terminal_style()

// Require vender autoload
require_once('../vendor/autoload.php');

// Print red text 
echo terminal_style('Here your text', 'red');

Overview

PHP Terminal style all styles

Custom background

PHP Terminal style custom backgroud

See custom background color

统计信息

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

GitHub 信息

  • Stars: 19
  • Watchers: 1
  • Forks: 10
  • 开发语言: PHP

其他信息

  • 授权协议: Apache-2.0
  • 更新时间: 2017-04-20