Skip to content

cliffparnitzky/FormDependentMandatoryField

Repository files navigation

Latest Version on Packagist Installations via composer per month Installations via composer total

Contao Extension: FormDependentMandatoryField

Provides an additional option for form field to be defined as dependent mandatory. Field is mandatory if another field (or more) is filled / or not.

Installation

Install the extension via composer: cliffparnitzky/form-dependent-mandatory-field.

If you prefer to install it manually, download the latest release here: https://github.com/cliffparnitzky/FormDependentMandatoryField/releases

Tracker

https://github.com/cliffparnitzky/FormDependentMandatoryField/issues

Compatibility

  • Contao version >= 3.2.0 ... < 3.6.0
  • Contao version >= 4.4.0

Dependency

This extension is dependent on the following extensions:

Screenshot

Screenshot 1 Screenshot 2

Additional information

CSS Tip

Adding special css, will show the difference between mandatory and dependent mandatory form fields.

This is only an example:

label.dependent.mandatory:after {
	content: '(*)';
	font-size: 9px;
	vertical-align: super;
	color: #FF7777;
}

With the css above, a form like the following will be created:

Screenshot 3

About

Contao extension: Provides an additional option for form field to be defined as dependent mandatory. Field is mandatory if another field is filled / or not.

Resources

License

Stars

Watchers

Forks

Sponsor this project

 

Packages

No packages published

Languages