Elementor: Disabling a Form Field

Let’s say you have a form field where you have dynamic data being brought in and you don’t want users to edit that data. You could always make that a hidden field within the Elementor Form widget. However, if you want it to be shown to the user, you can add some JavaScript code to disable that form field. Below is the code for disabling a form field in Elementor:


<script>
document.getElementById("FIELD_ID").disabled = true;
</script>

Please note, that you will have to copy over the field ID into the JS code from your Elementor Form. Also, put “form-field-” before the actual ID. For example, if the ID of your field was “product-item“, then you would put “form-field-product-item” for the FIELD_ID in the JS code.

Other Helpful Articles

Online Generator for Writing a Privacy Policy

Many websites need a privacy policy page. WordPress actually has a pre-built privacy policy page that users can edit. However, editing what they give you can be a little overwhelming. Furthermore, depending on your business, it may be better to use a lawyer to write up a more detailed privacy

Read More »

Elementor: Disabling a Form Field

Let’s say you have a form field where you have dynamic data being brought in and you don’t want users to edit that data. You could always make that a hidden field within the Elementor Form widget. However, if you want it to be shown to the user, you can

Read More »

What Do You Need Done?:

(Please check all that apply)

Tell Us About You

Almost Done!

Let's Get Some Info

Let's Get Some Info

Let's Get Some Info

Let's Get Some Info

Let's Get Some Info