ChronoEngine.com homepage

Forums

Please write a review for the extension you are using on the Joomla extensions directory before posting a new question as we are being spammed by many negative reviews.

Thank you for your support!

Dynamic dropdown with Repeater

Elita 03 Dec, 2017
Hello, could anybody tell me how to implement dynamic dropdown with Repeater?
Demos form Dynamic dropdown contains PHP code that I cannot get working with the repeater probably because first dropdown name and ID has changed from
what_do_you_think to something like this: Model[{var:area_repeater3.key}][what_do_you_think]. Im not good with the php, so would appreciate help.

$options = [];
switch($this->data('what_do_you_think')){
case 'good':
$options = ['1' => '1', '2' => '2', '3' => '3'];
break;
case 'bad':
$options = ['-1' => '-1', '-2' => '-2', '-3' => '-3'];
break;
case 'so':
$options = ['good' => 'Good', 'bad' => 'Bad'];
break;
}
return $options;
This topic is locked and no more replies can be posted.

2Checkout.com

2CheckOut.com Inc. (Ohio, USA) is an authorized retailer for goods and services provided by ChronoEngine.com