承接 pooley182/emoji-regex-pattern 相关项目开发

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

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

pooley182/emoji-regex-pattern

Composer 安装命令:

composer require pooley182/emoji-regex-pattern

包简介

PHP regexp pattern matching Unicode emojis

README 文档

README

This package for PHP builds a regex pattern that will match any emojis as defined by the Unicode consortium. It's especially useful when validating user submitted data if you want to remove emojis to sanitise your data.

versioning

This package does not follow typical symantic versioning rules. Typical version numbering would follow the convention X.Y.Z where X is a major version which denotes breaking changes in the package, Y would be a minor version that introduces new features but doesn't break anything, and Z would be a patch version that fixes up some code without any major changes or new features.

The version numbers of this package follow the versioning numbers of the Unicode Consortiums Emojis. V14.0 of this package will match all emojis within the consortiums V14.0 Emoji set. V15.0 of this package matches the consortiums V15.0 set of emojis. etc.

Therefore we recommend installing this package with composer require pooley182/emoji-regex-pattern ">=14.0.2", this will mean that as new emoji character sets are released your composer package will be updated to match them.

How to use

Install

composer require pooley182/emoji-regex-pattern ">=14.0.2"

Usage

use Pooley182\EmojiRegexPattern\EmojiRegexPattern;

private function hasEmojis($string) {
    $emojiRegexPattern = '/'.EmojiRegexPattern::getEmojiPattern().'/u';

    preg_match($emojiRegexPattern, $string, $matches);

    return !empty($matches);
}

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: MIT
  • 更新时间: 2022-06-25

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固