Jump to content

form setting to toggle on html

Recommended Posts

Is there a way to toggle on a $form->addHtml(' '); in the settings, for example

$form->add( new \IPS\Helpers\Form\YesNo( 'ShowHTMLForm', \IPS\Settings::i()->ShowHTMLForm, FALSE, array('togglesOn' => array( 'The_setting_below' ) ) ) );

$form->addHtml('I want this to display if ShowHTMLForm = 1 ');


Link to comment
Share on other sites

4 minutes ago, newbie LAC said:

$form->add( new \IPS\Helpers\Form\YesNo( 'ShowHTMLForm', \IPS\Settings::i()->ShowHTMLForm, FALSE, array('togglesOn' => array( 'my_custom_id' ) ) ) );

$form->addHtml('<div id="my_custom_id">Text</div>');


Perfect your a legend thanks

Link to comment
Share on other sites


This topic is now archived and is closed to further replies.

  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...