Invision Community 4: SEO, prepare for v5 and dormant account notifications Matt November 11, 2024Nov 11
Posted June 6, 20186 yr Example: $form->add( new \IPS\Helpers\Form\Radio('something', null, true, [ 'options' => [ 'opt1' => 'val1', 'opt2' => 'val2', ], 'toggles' => [ 'opt1' => ['text_container'], 'opt2' => ['text_container'] ] ]) ); $form->add(new \IPS\Helpers\Form\Text('text_input_id', null, true, [ 'placeholder' => \IPS\Member::loggedIn()->language()->get('text_input_placeholder'), 'minLength' => 1, 'maxLength' => 14, ], function ($val) { // not interesting }, null, null, 'text_container')); Can i set different placeholder on text input depending on current radio option selected? Or i can do it only with javascript way? Thanks!
June 6, 20186 yr Since you're talking about changing the placeholder text based on the current radio button choice, jQuery/Javascript would be the only way to do that as the user changed the radio button selection.
June 6, 20186 yr Author 22 minutes ago, Joy Rex said: Since you're talking about changing the placeholder text based on the current radio button choice, jQuery/Javascript would be the only way to do that as the user changed the radio button selection. Thanks for support my assumption. Already start doing in this way
Archived
This topic is now archived and is closed to further replies.