PHPackages                             zouhuigang/phpesc - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Search &amp; Filtering](/categories/search)
4. /
5. zouhuigang/phpesc

ActiveLibrary[Search &amp; Filtering](/categories/search)

zouhuigang/phpesc
=================

php esc search

011PHP

Since Sep 1Pushed 8y ago1 watchersCompare

[ Source](https://github.com/zouhuigang/php-esc)[ Packagist](https://packagist.org/packages/zouhuigang/phpesc)[ RSS](/packages/zouhuigang-phpesc/feed)WikiDiscussions master Synced 3d ago

READMEChangelogDependenciesVersions (1)Used By (0)

### esc库使用说明

[](#esc库使用说明)

### 使用方法

[](#使用方法)

下载

```
composer require "zouhuigang/phpesc:dev-master"
composer remove "zouhuigang/phpesc:dev-master" //移除,但是不删除本地的库文件

```

想要彻底删除，可以在根目录中的composer.json将本库移除掉，然后composer update,即可删除本地库文件

使用

```
use package\phpesc as phpesc;
$esc=new phpesc\Esc();

```

查询数据：

```
curl 'localhost:9200/accounts/person/_search'  -d '
	{
	  "query" : { "match" : { "desc" : "软件" }}
	}'

```

esc方式：

```
$esc->_search('{"query":{"match":{"desc":"软件"}}}')

```

新建数据：

```
curl -X PUT 'localhost:9200/accounts/person/1' -d '
{
  "user": "张三",
  "title": "工程师",
  "desc": "数据库管理"
}'

```

esc方式：

```
$array = array('index' => 'accounts','type' => 'person','id' => '4');

$esc->create($array,'{
	  "user": "张三",
	  "title": "工程师",
	  "desc": "数据库管理"
	}');

```

###  Health Score

20

—

LowBetter than 14% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity41

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

### Community

Maintainers

![](https://www.gravatar.com/avatar/10ff9cbe56171de5d4044908014b0b02cac2b3c589b1b2ffff3732fa8b45b304?d=identicon)[zouhuigang](/maintainers/zouhuigang)

---

Top Contributors

[![zouhuigang](https://avatars.githubusercontent.com/u/15059874?v=4)](https://github.com/zouhuigang "zouhuigang (7 commits)")

### Embed Badge

![Health badge](/badges/zouhuigang-phpesc/health.svg)

```
[![Health](https://phpackages.com/badges/zouhuigang-phpesc/health.svg)](https://phpackages.com/packages/zouhuigang-phpesc)
```

###  Alternatives

[ruflin/elastica

Elasticsearch Client

2.3k50.4M203](/packages/ruflin-elastica)[opensearch-project/opensearch-php

PHP Client for OpenSearch

15024.3M65](/packages/opensearch-project-opensearch-php)[mailerlite/laravel-elasticsearch

An easy way to use the official PHP ElasticSearch client in your Laravel applications.

934529.3k2](/packages/mailerlite-laravel-elasticsearch)[massive/search-bundle

Massive Search Bundle

721.4M13](/packages/massive-search-bundle)[shyim/opensearch-php-dsl

OpenSearch/Elasticsearch DSL library

175.9M9](/packages/shyim-opensearch-php-dsl)[outl1ne/nova-multiselect-filter

Multiselect filter for Laravel Nova.

45802.7k3](/packages/outl1ne-nova-multiselect-filter)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
