vitexsoftware/ease-framework
最新稳定版本:1.29
Composer 安装命令:
composer require vitexsoftware/ease-framework
包简介
An PHP Framework for Ease of writing Applications
README 文档
README
EasePHP Framework
Object oriented PHP Framework for easy&fast writing small/middle sized apps.
Installation
Download https://github.com/VitexSoftware/EaseFramework/archive/master.zip or use
Composer:
composer require vitexsoftware/ease-framework
Linux
For Debian, Ubuntu & friends please use repo:
wget -O - http://v.s.cz/info@vitexsoftware.cz.gpg.key|sudo apt-key add -
echo deb http://v.s.cz/ stable main | sudo tee /etc/apt/sources.list.d/vitexsoftware.list
sudo apt update
sudo apt install ease-framework
In this case please add this to your app composer.json:
"require": { "ease-framework": "*" }, "repositories": [ { "type": "path", "url": "/usr/share/php/Ease", "options": { "symlink": true } } ]
Docker:
To get Docker image:
docker pull vitexsoftware/easephpframework
Framework Constants
- EASE_APPNAME - common name of application. Mainly used in logs.
- EASE_LOGGER - one of memory,console,file,syslog,email,std,eventlog or combination "console|syslog"
- EASE_EMAILTO - recipient for Ease/Logger/ToMail
- EASE_SMTP - Custom SMTP Settings (JSON Encoded)
- DB_TYPE - pgsql|mysql|sqlite|...
- DB_HOST - localhost is default
- DB_PORT - database port
- DB_DATABASE - database schema name
- DB_USERNAME - database user login name
- DB_PASSWORD - database user password
- DB_SETUP - database setup command (executed directly after connect)
Example
Twitter Bootstrap page with simple Form
$oPage = new \Ease\TWB\WebPage('Page title'); $form = $oPage->addItem( new \Ease\TWB\Form('ExampleForm') ); $form->addItem(new \Ease\Html\InputTextTag('Name')); $form->addItem(new \Ease\TWB\SubmitButton('OK', 'success') ); $oPage->draw();
Logging
You can use any combination of this logging modules:
- memory - log to array in memory
- console - log to ansi sequence capable console
- file - log to specified file
- syslog - log to linux syslog service
- email - send all messages to constant('EASE_EMAILTO') at end
- std - write messages to stdout/stderr
- eventlog - log to Windows eventlog
define('EASE_LOGGER', 'console|syslog'); $logger = new \Ease\Sand(); $logger->addStatusMessage('Error Message', 'error');
Testing
At first you need initialise create sql user & database with login and password from testing/phinx.yml and initialise testing database by phinx migrate command:
composer update
cd tests
mysqladmin -u root -p create easetest
mysql -u root -p -e "GRANT ALL PRIVILEGES ON easetest.* TO easetest@localhost IDENTIFIED BY 'easetest'"
sudo -u postgres bash -c "psql -c \"CREATE USER easetest WITH PASSWORD 'easetest';\""
sudo -u postgres bash -c "psql -c \"create database easetest with owner easetest encoding='utf8' template template0;\""
../vendor/bin/phinx migrate -e development
../vendor/bin/phinx migrate -e testing
Building
Simply run make deb
Links
Homepage: https://www.vitexsoftware.cz/ease.php
GitHub: https://github.com/VitexSoftware/EaseFramework
Apigen Docs: https://www.vitexsoftware.cz/ease-framework/
Modular & Lightweight successor library: https://github.com/VitexSoftware/ease-core
vitexsoftware/ease-framework 适用场景与选型建议
vitexsoftware/ease-framework 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 23.15k 次下载、GitHub Stars 达 6, 最近一次更新时间为 2015 年 07 月 14 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 vitexsoftware/ease-framework 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 vitexsoftware/ease-framework 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 23.15k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 6
- 点击次数: 5
- 依赖项目数: 4
- 推荐数: 0
其他信息
- 授权协议: GPL-2.0-or-later
- 更新时间: 2015-07-14
