wrey75/concerto
Composer 安装命令:
composer require wrey75/concerto
包简介
A basic library for PHP projects
README 文档
README
This library is now mature.
It is currently used in production for the French website http://www.koikonfait.com/ . I mean there is no official release yet and the documentation is mainly inside the source code (which is nice for autocompletion in Eclipse).
Notes
This library is an inheritance of several classes created from old PHP versions (I mean, PHP 4 or even PHP 3) and involved in several projets. Concerto is a rewrite using a namespace and very simple capabilities.
This idea behind Concerto is to offer some "out-of-the box" capabilities for some weak points in PHP:
- UTF-8 support (through std::XXX static functions).
- Logging capabilities (beta).
- SQL capabilities based on a thin layer over PDO (beta).
- DAO (Data Access Object) upon the SQL class (beta).
- A simple to use O/R mapping. Simpler than Hibernate but having some capabilities included like optimistic updates, etc.
A basic application
Based on what we know about applications, a BasicApplication offers a way to use easily an out-of-box application. Check the documentation of the class to see how you can extend this class.
The std class
The basic class used everywhere. This class is basically an "helper" having all the methods static. Once of my favorite is the "tag()" which creates a HTML tag based on the tag name and their attributes passed as an array. The method is in charge of cleaning the text in the values of the attributes.
If you use "get()" to retrieve values passed in the query string, you have a default behaviour translating "<" into "< " to ruin efforts to try XSS on your site. It is working to avoid script injection, but there is no SQL protection because you should use the mapping rather than creating SQL sentences manually.
The Logger class
To log data. You can create as many loggers as you want.
The DataTable class
Used to print tables (using the "<table>" tag). Note this class uses the DataTables JQuery library which can be a little old-style but working pretty well for 90% of the basic needs. There are some very enthousiastic mathods to avoid coding Javascript for this library.
wrey75/concerto 适用场景与选型建议
wrey75/concerto 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 464 次下载、GitHub Stars 达 1, 最近一次更新时间为 2015 年 11 月 04 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 wrey75/concerto 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 wrey75/concerto 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 464
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 8
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: Apache-2.0
- 更新时间: 2015-11-04