PHPackages                             codemenorg/fakefield - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. codemenorg/fakefield

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

codemenorg/fakefield
====================

Hide original field name from end user.

v1.1.3(6y ago)9373MITPHPPHP ^7.1

Since Mar 30Pushed 6y ago4 watchersCompare

[ Source](https://github.com/codemenorg/fakefield)[ Packagist](https://packagist.org/packages/codemenorg/fakefield)[ Docs](https://github.com/codemenorg/fakefield)[ RSS](/packages/codemenorg-fakefield/feed)WikiDiscussions master Synced 2d ago

READMEChangelog (5)DependenciesVersions (7)Used By (0)

Laravel Fake Field
==================

[](#laravel-fake-field)

[![Latest Stable Version](https://camo.githubusercontent.com/6f100361efc95cb1d7fe0d721fa28e9e3a014c47399e0382c28f9f2ba485c2bd/68747470733a2f2f706f7365722e707567782e6f72672f636f64656d656e6f72672f66616b656669656c642f762f737461626c65)](https://packagist.org/packages/codemenorg/fakefield)[![Latest Unstable Version](https://camo.githubusercontent.com/41b67c1d755fc210c210bfa10cef389d4e0753cfbbe01e7dbe6a78a76b1b248e/68747470733a2f2f706f7365722e707567782e6f72672f636f64656d656e6f72672f66616b656669656c642f762f756e737461626c65)](https://packagist.org/packages/codemenorg/fakefield)[![License](https://camo.githubusercontent.com/38d2602683557473ee79a3f8b325ba9a36264f63b3498a3dec23a0df016868aa/68747470733a2f2f706f7365722e707567782e6f72672f636f64656d656e6f72672f66616b656669656c642f6c6963656e7365)](https://packagist.org/packages/codemenorg/fakefield)[![Total Downloads](https://camo.githubusercontent.com/4d86f039d06464a4889327bce6caf746271be198313a47c84f87cab558a772c4/68747470733a2f2f706f7365722e707567782e6f72672f636f64656d656e6f72672f66616b656669656c642f646f776e6c6f616473)](https://packagist.org/packages/codemenorg/fakefield)

Hide original field name from end user. It will generate new field name(fake field) every time while you refresh your page.

Installation
------------

[](#installation)

You can install the package via composer:

```
composer require codemenorg/fakefield
```

For Laravel 5.8 use `composer require codemenorg/fakefield:1.0.0`

Usage
-----

[](#usage)

After installing the package, run the following command to generate `fakefield.php` config file. Here you have to define fake field prefix and Eloquent Model path.

```
php artisan vendor:publish --tag=fake-field-config

```

Add `FakeFieldMiddleware` to `app\Http\Kernel.php` web middleware group section.

```
protected $middlewareGroups = [
        'web' => [
            ...
            \Codemen\FakeField\FakeFieldMiddleware::class,
        ],
        ...
    ];
```

Inside your model you have to define which fields you want to change.

```
protected $fakeFields = ['first_name', 'last_name', 'email'];
```

Now you are ready to use fake field inside your form.

```

    @csrf
    @fakeKey

    Submit

```

Here `@fakeKey` blade directive will generate a fake key without fake field will not working properly. You can also use `fake_key()` helper function to generate fake key.

`fake_field()` helper function will generate fake field.

**If the field is not defined in Model then the function will return original field name.**

### Changelog

[](#changelog)

Please see [CHANGELOG](CHANGELOG.md) for more information what has changed recently.

Contributing
------------

[](#contributing)

To contribute you can create a pull request. But please check all functionality are working before creating pull request. We will publish your name on contribution list.

### Security

[](#security)

If you discover any security related issues, please email  instead of using the issue tracker.

Credits
-------

[](#credits)

- [Codemen](https://github.com/codemenorg)
- [All Contributors](../../contributors)

License
-------

[](#license)

The MIT License (MIT). Please see [License File](LICENSE.md) for more information.

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity15

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity60

Established project with proven stability

 Bus Factor1

Top contributor holds 77.8% 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.

###  Release Activity

Cadence

Every ~56 days

Total

5

Last Release

2422d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/b36d8e181d00f763781a06578b856b2ec1229675e8341b18fb932c5eb61c394a?d=identicon)[codemen](/maintainers/codemen)

---

Top Contributors

[![ranabd36](https://avatars.githubusercontent.com/u/8455801?v=4)](https://github.com/ranabd36 "ranabd36 (14 commits)")[![codemenorg](https://avatars.githubusercontent.com/u/46299549?v=4)](https://github.com/codemenorg "codemenorg (4 commits)")

---

Tags

laravel-packagecodemenfakefield

### Embed Badge

![Health badge](/badges/codemenorg-fakefield/health.svg)

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

###  Alternatives

[realrashid/sweet-alert

Laravel Sweet Alert Is A Package For Laravel Provides An Easy Way To Display Alert Messages Using The SweetAlert2 Library.

1.2k3.1M22](/packages/realrashid-sweet-alert)[ashallendesign/short-url

A Laravel package for creating shortened URLs for your web apps.

1.4k2.2M5](/packages/ashallendesign-short-url)[imanghafoori/laravel-nullable

A package to help you write expressive defensive code in a functional manner

151461.3k6](/packages/imanghafoori-laravel-nullable)[erag/laravel-pwa

A simple and easy-to-use PWA (Progressive Web App) package for Laravel applications.

179110.0k](/packages/erag-laravel-pwa)[deligoez/laravel-model-hashid

Generate, Save, and Route Stripe/Youtube-like Hash IDs for Laravel Eloquent Models

166109.2k](/packages/deligoez-laravel-model-hashid)[helgesverre/extractor

AI-Powered Data Extraction for your Laravel application.

22333.1k](/packages/helgesverre-extractor)

PHPackages © 2026

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