Docs & Support

Learn about all the Formidable features and get support from our amazing customer success team.

AngularJS Examples

AngularJS is a JavaScript-based open-source front-end web application framework mainly maintained by Google and a few others. Learn more and download the AngularJS library. You can use AngularJS examples to more easily do a few things that are not as simple with JavaScript.

If you would like to stick strictly to vanilla JavaScript and jQuery, see these examples.

Utilize user input in field labels

This AngularJS example makes it easy for a field label title to reflect what the user typed in a previous field in the same form. For example, if a user types their name in a field, and you want for their name to show up in a field label of another field in the same form, you can use this example.

Note: This example is not configured to work with multi-page forms and will require additional customization.

  1. Download the AngularJS library and install it on your site (recommended) or add a link to the library in Customize HTML > "Before Fields":
    <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.6.4/angular.min.js"></script>

    AngularJS Examples before fields

  2. At the end of the "Before Fields" section in Customize HTML, add:
    <div ng-app="">

    and add:

    </div>

    at the top of the "After Fields" section. AngularJS Examples After Fields Content

  3. For each field that you want to use in another field's label, add:
    ng-model="field-name-here"

    inside the input shortcode. For example, if I have a Name field and I want to make use of the user's name in another field label, I would change my input shortcode for the Name field from [input] to:

    [input ng-model="Name"]

    AngularJS Examples Input Shortcode Changes

  4. In the Form Builder, for each field input that I set up on the back-end, add {{field-name-here}} to the field Label. For example, with the case of using the user's name, I would add a field label like this: "Tell us something about yourself, {{Name}}" AngularJS Examples Field Label Example

Now when you preview the form and type 'Robert' in the "Name" field, the next field label should read: "Tell us something about yourself, Robert". AngularJS Examples Final Example of Functionality

Was this article helpful? *

This article may contain affiliate links. Once in a while, we earn commissions from those links. But we only recommend products we like, with or without commissions.

In this article

    We have a small, but amazing team of dedicated people who are committed to helping you achieve your goals and project requirements.


    Copyright © 2025 Strategy11, LLC. Formidable Forms® is a registered trademark Strategy11, LLC.

    Join 400,000+ using Formidable Forms to create form-focused solutions fast. Get Formidable Forms