PHPackages                             heimrichhannot/contao-form-autocomplete-bundle - 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. heimrichhannot/contao-form-autocomplete-bundle

ActiveContao-bundle[Utility &amp; Helpers](/categories/utility)

heimrichhannot/contao-form-autocomplete-bundle
==============================================

This bundle offers functionality for adding the HTML5 attribute "autocomplete" to form fields in the Contao CMS.

1.3.1(1y ago)02.1k1LGPL-3.0-or-laterPHPPHP ^7.2 || ^8.0

Since Sep 2Pushed 1y ago4 watchersCompare

[ Source](https://github.com/heimrichhannot/contao-form-autocomplete-bundle)[ Packagist](https://packagist.org/packages/heimrichhannot/contao-form-autocomplete-bundle)[ RSS](/packages/heimrichhannot-contao-form-autocomplete-bundle/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (5)Dependencies (5)Versions (9)Used By (0)

Contao Form Autocomplete Bundle
===============================

[](#contao-form-autocomplete-bundle)

This bundle offers functionality for adding the HTML5 attribute `autocomplete` to form fields in the Contao CMS.

The `autocomplete` attribute is used in the following cases:

1. Browsers use it for presenting different autocompletion options for fields wth different `autocomplete` value set.
2. Screen readers verbalize it, hence it's a good practice to have them set.

Features
--------

[](#features)

- adds the HTML5 `autocomplete` attribute to form fields
- supports:
    - Contao Formgenerator
    - all form fields generated by using Widget::parse() (the hook getAttributesFromDca is used)

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

[](#installation)

1. Install via composer: `composer require heimrichhannot/contao-form-autocomplete-bundle`.

How does it work?
-----------------

[](#how-does-it-work)

### Form generator

[](#form-generator)

The form generator is supported by default. The `autocomplete` value is guessed based on the field name. The value is guessed based on the mapping defined in the bundle config. You can extend this mapping in your project (see chapter below).

### Dca fields

[](#dca-fields)

There are the following supported ways to add the `autocomplete` value to a field (the priority is descending):

1. The DCA definition has it set in its `eval` section: ```
    // tl_my_table.php
    'myFirstnameField' => [
       'label' => &$GLOBALS['TL_LANG']['tl_my_table']['myFirstnameField'],
       // ...
       'eval' => [
           'autocomplete' => 'given-name'
       ]
    ]

    ```
2. If no DCA definition is found or relevant in the given context (e.g. in form generator there is no DCA context), the bundle tries to guess based on the mapping of field name to `autocomplete` value defined in this bundle. You can extend this mapping in your project (see chapter below).

Technical details
-----------------

[](#technical-details)

### Extend the given mapping

[](#extend-the-given-mapping)

Simply add the following code according to your needs to your `app/config/config.yml` (Contao 4.4) or `config/config.yml`:

```
huh_form_autocomplete:
  mapping:
    given-name:
      synonyms:
        - my-new-value
    new-autocomplete-name:
      synonyms:
        - brand-new-autocomplete-name
```

### How does the matching of a field name and an autocomplete value work?

[](#how-does-the-matching-of-a-field-name-and-an-autocomplete-value-work)

The algorithm is currently very simple. Basically it works the following way:

1. If an `autocomplete` value is set in the field's DCA, it's used.
2. The mapping in `src/Resources/config/config.yml` contains all the currently possible values of the HTML5 `autocomplete` field. If the field name equals one of these, it's used.
3. If the step before isn't met, the algorithm iterates the defined synonyms of the `autocomplete` values. If there's a match, the corresponding `autocomplete` value is used.
4. If none of the steps above is met, `false` is returned.

The comparison only takes into account characters. Special characters and separation characters like `-` or `_` are ignored. Hence a synonym `some-name` equals `someName` in this comparison.

###  Health Score

35

—

LowBetter than 80% of packages

Maintenance31

Infrequent updates — may be unmaintained

Popularity20

Limited adoption so far

Community13

Small or concentrated contributor base

Maturity65

Established project with proven stability

 Bus Factor1

Top contributor holds 50% 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 ~193 days

Recently: every ~248 days

Total

8

Last Release

727d ago

PHP version history (4 changes)1.0.0PHP ^7.2

1.1.0PHP ^7.2|^8.0

1.2.0PHP ^7.2||^8.0

1.3.1PHP ^7.2 || ^8.0

### Community

Maintainers

![](https://www.gravatar.com/avatar/28ad3224d8727b622ebd229840eea6b9dbcb83eb0bd609e6ce65b614830ff538?d=identicon)[digitales@heimrich-hannot.de](/maintainers/digitales@heimrich-hannot.de)

---

Top Contributors

[![ericges](https://avatars.githubusercontent.com/u/25957923?v=4)](https://github.com/ericges "ericges (2 commits)")[![amenk](https://avatars.githubusercontent.com/u/1087128?v=4)](https://github.com/amenk "amenk (1 commits)")[![koertho](https://avatars.githubusercontent.com/u/12064642?v=4)](https://github.com/koertho "koertho (1 commits)")

### Embed Badge

![Health badge](/badges/heimrichhannot-contao-form-autocomplete-bundle/health.svg)

```
[![Health](https://phpackages.com/badges/heimrichhannot-contao-form-autocomplete-bundle/health.svg)](https://phpackages.com/packages/heimrichhannot-contao-form-autocomplete-bundle)
```

###  Alternatives

[codefog/contao-haste

haste extension for Contao Open Source CMS

42650.8k139](/packages/codefog-contao-haste)[codefog/contao-news_categories

News Categories bundle for Contao Open Source CMS

3183.3k6](/packages/codefog-contao-news-categories)[numero2/contao-storelocator

Contao Plugin for managing stores (or in common address data) and providing a frontend-search based on geo data

121.5k](/packages/numero2-contao-storelocator)

PHPackages © 2026

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