elephpant/favicon
Composer 安装命令:
composer require elephpant/favicon
包简介
A simple way to generate multiple favicons.
关键字:
README 文档
README
Installation
Composer (recommended)
Use Composer to install this library from Packagist:
elephpant/favicon
Run the following command from your project directory to add the dependency:
composer require elephpant/favicon "^1.0"
Alternatively, add the dependency directly to your composer.json file:
"require": { "elephpant/favicon": "^1.0" }
Usage
<?php use ElePHPant\Favicon\Favicon; // ORIGINAL IMAGE (recommended minimum size: 310x310 px), FOLDER, SITE URL $favicon = (new Favicon('source.png', 'img/ico', 'https://site.com')) ->favicon() ->render();
<head> <meta charset="UTF-8"> <title>Document</title> <!-- ========== Favicon ========== --> <?= $favicon; ?> </head>
Basic Result
<head> <meta charset="UTF-8"> <title>Document</title> <!-- ========== Favicon ========== --> <link rel="apple-touch-icon-precomposed" href="https://site.com/img/ico/apple-touch-icon-57x57.png" sizes="57x57"/> <link rel="apple-touch-icon-precomposed" href="https://site.com/img/ico/apple-touch-icon-114x114.png" sizes="114x114"/> <link rel="apple-touch-icon-precomposed" href="https://site.com/img/ico/apple-touch-icon-72x72.png" sizes="72x72"/> <link rel="apple-touch-icon-precomposed" href="https://site.com/img/ico/apple-touch-icon-144x144.png" sizes="144x144"/> <link rel="apple-touch-icon-precomposed" href="https://site.com/img/ico/apple-touch-icon-60x60.png" sizes="60x60"/> <link rel="apple-touch-icon-precomposed" href="https://site.com/img/ico/apple-touch-icon-120x120.png" sizes="120x120"/> <link rel="apple-touch-icon-precomposed" href="https://site.com/img/ico/apple-touch-icon-76x76.png" sizes="76x76"/> <link rel="apple-touch-icon-precomposed" href="https://site.com/img/ico/apple-touch-icon-152x152.png" sizes="152x152"/> <link rel="icon" href="https://site.com/img/ico/favicon-196x196.png" sizes="196x196" type="image/png"/> <link rel="icon" href="https://site.com/img/ico/favicon-96x96.png" sizes="96x96" type="image/png"/> <link rel="icon" href="https://site.com/img/ico/favicon-32x32.png" sizes="32x32" type="image/png"/> <link rel="icon" href="https://site.com/img/ico/favicon-16x16.png" sizes="16x16" type="image/png"/> <link rel="icon" href="https://site.com/img/ico/favicon-128x128.png" sizes="128x128" type="image/png"/> <meta name="application-name" content="&nbsp;"/> <meta name="msapplication-TileColor" content="#FFFFFF"/> <meta name="msapplication-TileImage" content="https://site.com/img/ico/mstile-144x144.png"/> <meta name="msapplication-square70x70logo" content="https://site.com/img/ico/mstile-70x70.png"/> <meta name="msapplication-square150x150logo" content="https://site.com/img/ico/mstile-150x150.png"/> <meta name="msapplication-wide310x150logo" content="https://site.com/img/ico/mstile-310x150.png"/> <meta name="msapplication-square310x310logo" content="https://site.com/img/ico/mstile-310x310.png"/> </head>
RSS (optional parameter)
<meta name="msapplication-notification" content="frequency=30;polling-uri=https://notifications.buildmypinnedsite.com/?feed=https://site.com/rss.xml.xml&id=1;polling-uri2=https://notifications.buildmypinnedsite.com/?feed=https://site.com/rss.xml.xml&id=2;polling-uri3=https://notifications.buildmypinnedsite.com/?feed=https://site.com/rss.xml.xml&id=3;polling-uri4=https://notifications.buildmypinnedsite.com/?feed=https://site.com/rss.xml.xml&id=4;polling-uri5=https://notifications.buildmypinnedsite.com/?feed=https://site.com/rss.xml.xml&id=5;cycle=1"/>
Contributing
No one ever has enough engineers, so we're very happy to accept contributions via Pull Requests. For details, see CONTRIBUTING
Credits
- Wilder Amorim (Developer)
- All Contributors (This Rock)
License
The MIT License (MIT). Please see License File for more information.
elephpant/favicon 适用场景与选型建议
elephpant/favicon 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 163 次下载、GitHub Stars 达 4, 最近一次更新时间为 2020 年 09 月 29 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「favicon」 「ElePHPant」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 elephpant/favicon 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 elephpant/favicon 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 elephpant/favicon 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
PHP Library to get the apple-touch-icons and favicon from a website.
A favicon extractor for Laravel
Adding favicons to your site the simple way.
Generate realfavicon from your Statamic control panel
Simplistic templating for adding favicons for multiple devices
A simple and effective way to work with Cookies
统计信息
- 总下载量: 163
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 7
- 点击次数: 10
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2020-09-29