Joomla 5 Mitteilung

Wir freuen uns mitteilen zu können, dass seit dem 29. Januar 2024 alle unsere Joomla Erweiterungen mit Joomla 5 kompatible sind.

Für alle die gerade noch von Joomla 3 auf 4 aktualisieren: Anleitungen für die Joomla 4 Migration gibt es hier:

Es gibt nun auch eine eigenständige Dokumentation für Visforms für Joomla 4 und für Visforms auf Joomla 5

Forum

Visforms Subscription Inhaber können in unserem Forum Fragen stellen. Bitte mit dem entsprechenden Benutzer anmelden.
Jeder kann lesend auf das Forum zugreifen.

Bitte stellen Sie nur 1 Frage pro Thema.

Check value in calculation field

Mehr
2 Monate 1 Woche her #10105 von geert@huizechaos.be
Check value in calculation field wurde erstellt von geert@huizechaos.be
Hello,
I'm designing a form to track samples of bees from different hives. The idea is that the beekeeper takes a sample of 10 bees and puts them in a canister that has a sample number. The beekeeper has to enter this number in the form relative to the hive from which the sample is taken.
To avoid errors I want to include a check: the 4 first digits of the number are the sample number, the 2 next digits represent the remainder of the sample number divided by 97. ex. 70 being the remainder of 1234/97, 123470 is a valid number 123407 is not. (the same system is used in bank account numbers, at least in Belgium).
In a calculation field I can extract the entered check number and the calculated check number but I have no way to compare them....
Should I look into regular expressions? I hope not...
Kind regards,
Geert

Mehr
2 Monate 1 Woche her - 2 Monate 1 Woche her #10106 von Administrator IV
Administrator IV antwortete auf Check value in calculation field
Hello Geert,

Calculation fields can do a lot and are sufficient in many places.
Due to the highest possible security, the calculation becomes independent of each other
- a first time locally in the browser in JavaScript and
- done a second time in PHP in the backend.

However, this results in an intersection of the available functions and actions that you can use.
Because the code must be executable for JavaScript and PHP at the same time.

In your case, it is better if you implement your individual solution with JavaScript and the 'Visforms web assets'.
Here you have virtually all the options you need.
You can react (a field value changes), calculate and act as you wish (influence other fields).

You simply add your JavaScript code to the affected Visforms view (form, data, ...) using the Visforms 'Frontend Webassets'.
The procedure is described in the documentation.

Frontend web assets:
docs.joomla-5.visforms.vi-solutions.de/e...-frontend-webassets/
All settings are made in the form:
docs.joomla-5.visforms.vi-solutions.de/e...are-made-in-the-form
Examples of solving requirements with the frontend web assets:
docs.joomla-5.visforms.vi-solutions.de/e...-webassets/examples/

Kind regards, Ingmar

:idea: I recommend you the new and up-to-date documentation for Joomla 4:
docs.joomla-5.visforms.vi-solutions.de/en/docs/
Most of this also applies retrospectively to Joomla 3.
Please only ask 1 question per topic :-).

:idea: Ich empfehle Dir die neue und aktuelle Dokumentation für Joomla 4:
docs.joomla-5.visforms.vi-solutions.de/docs/
Das meiste gilt rückwirkend auch für Joomla 3.
Bitte immer nur 1 Frage pro Thema stellen :-).
Letzte Änderung: 2 Monate 1 Woche her von Administrator IV.
Folgende Benutzer bedankten sich: geert@huizechaos.be

Moderatoren: Administrator AVAdministrator IV
Powered by Kunena Forum