Forums

Multiplier - why doesn't it show the 'start count' number of repeats?

fribse 24 Apr, 2016
Hi All

Ok, I'm getting very close to having a very nice form for calculating our boattrips.
The input works, the calculations work, and the presentation of the results work, I just need to adjust the design of the input, and do some more input validations.
I've set the Multiplier, to have a 'start count' of two, and have set 'hide first' + 'disable first', but I don't see any of the multiplied fields appear at all when the form loads. How do I make it do that?
GreyHead 25 Apr, 2016
Hi fribse,

Please post a link to the form so I can take a quick look.

Bob
fribse 25 Apr, 2016
Its here:
https://www.dkdb.dk/index.php?option=com_chronoforms5&chronoform=TripCalculator
I also see another strange thing, when I do an event loop because of an error, I see one less participant than originally submitted.

I'm trying to find a more clever way of doing validation. Only one person can be set to have paid for that part of the expenses, and currently I've created a small PHP script that checks the form after pressing submit, but for now, it works.
fribse 29 Apr, 2016
This is the same form that you looked at in 'Printing the result from a form?'.
GreyHead 30 Apr, 2016
Answer
HI fribse,

As far as I recall ChronoForms handles the reloading correctly based on the data in the $form->data[''] arrray. Adding a Debugger will let you see what that is. You do need to make sure that the Multiplier elements are correctly names - you must hide the 'master' which has [__N__] or something similar as the index, and I would not use 0 as an index but start with 1.

Bob
fribse 30 Apr, 2016
Ahh, I found the problem, I had set the 'datapath':
[attachment=0]2.png[/attachment]
Removing that made it show the two I've set as a start.
This topic is locked and no more replies can be posted.