PHPackages                             humni/multi-step-form - 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. humni/multi-step-form

AbandonedArchivedLibrary

humni/multi-step-form
=====================

A 1 file multi-step form animator

3101JavaScript

Since Jul 5Pushed 8y agoCompare

[ Source](https://github.com/Humni/multi-step-form)[ Packagist](https://packagist.org/packages/humni/multi-step-form)[ RSS](/packages/humni-multi-step-form/feed)WikiDiscussions master Synced 2d ago

READMEChangelogDependenciesVersions (1)Used By (0)

humni/multi-step-form
=====================

[](#humnimulti-step-form)

Requires jQuery

This multi-step-form Animator handles the and submits multi-step forms. Each step is treated as its own form and is submitted and handled with event handlers. The goal is to create a robust multi-step form handler.

Documentation
-------------

[](#documentation)

#### Simple Example

[](#simple-example)

Include the `multi-step-form.min.js`

```
multiStepForm.init('.multi-step-form');
multiStepForm.addNextBtns('.multi-step-form-next');
multiStepForm.addPrevBtns('.multi-step-form-prev');

```

#### Custom Submit Handler Example

[](#custom-submit-handler-example)

```
multiStepForm.init('#steps-container');
multiStepForm.addNextBtns('.multi-step-form-next');

submitHandler = function (){
    var form = multiStepForm.getCurrentStep();

    //submit the form
    $.ajax({
        type: 'post',
        url: $(form).attr('action'),
        data: $(form).serialize(),
        success: function () {
            console.log('Success!');
        },
        error: function () {
            console.log('Error!');
        }
    });

    //This prevents any other submit handlers (including the default) from running
    return false;
}

//finally add the handler to the multiStepForm
multiStepForm.addHandler('submit', submitHandler);

```

#### Methods

[](#methods)

*init(selector)*
Sets up the multi-step-form with the selector for the container of the multi-step-form.

*addNextBtns(selector)*
Binds the `nextStep` to the click event of the specified selector

*addPrevBtns(selector)*
Binds the `prevStep` to the click event of the specified selector

*addHandler(event, function) : boolean*
This adds an event handler to one of the events. Use the `eventName` in the event parameter, and the function parameter must be a function. If a bound event handler returns `false`, the event will no longer bubble through the bound handlers. Handlers executed in order of which they are bound, with the default handler executing last.

This will return `true` if the hander was bound successfully.

*next()*
This will go to the next step

*prev()*
This will go to the previous step

*goToStep(step, submit = false)*
This will go to the specified step, and will submit the current step if `submit`is set to `true`.

*getCurrentStep() : jQueryObject*
Will return the current step of the multi-step form.

#### Events

[](#events)

*nextStep*
Called when going to the next step. `stepId` is the new step number

*prevStep*
Called when going to the previous step. `stepId` is the new step number

*submit*
Called to submit the forms for the current step. The default handler will use synchronous ajax to post the form to the forms action property.

###  Health Score

21

—

LowBetter than 19% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity9

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/37fec0bde9951987116e05a7498385119e6ea032426ed8718dd3f561bf7b2196?d=identicon)[humni](/maintainers/humni)

---

Top Contributors

[![Humni](https://avatars.githubusercontent.com/u/5545538?v=4)](https://github.com/Humni "Humni (2 commits)")

### Embed Badge

![Health badge](/badges/humni-multi-step-form/health.svg)

```
[![Health](https://phpackages.com/badges/humni-multi-step-form/health.svg)](https://phpackages.com/packages/humni-multi-step-form)
```

PHPackages © 2026

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