1

I'm creating a form using the Joomla XML form definition, and I want to create a range of integer values a user can select from. The number/integer field is fine for this use-- but I need to allow the first, last, and step parameters to be set by the user of the component. Is it possible to pass in variables to the XML form?

<field name="myintegervalue" type="integer" default="Some integer" label="Choose an integer" description="" first="1" last="10" step="1" />

I realize it's possible to create a custom field type, but then I'd end up re-inventing the wheel and building the select list with the min / max / step values and duplicating the JFormFieldNumber code.

3
  • So in your form, before your number field you will have 3 other fields that will set the min/max/step params?
    – FFrewin
    Commented Sep 8, 2018 at 17:26
  • This question has been recently answered here joomla.stackexchange.com/questions/23391/….
    – Sharky
    Commented Sep 8, 2018 at 19:53
  • @user101289 after reading the related solution that Sharky posted, if you still require support please update your question to be more specific about what you require. Commented Sep 8, 2018 at 21:32

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.