No Code Attached Yet
avatar Ruud68
Ruud68
26 Oct 2026

Steps to reproduce the issue

  1. In any component's administrator/components/com_xxx/config.xml, add a tab fieldset with child fieldsets, and put a showon on one of the children:
<fieldset name="exampletab" label="Example">
	<fieldset name="example_general" label="General">
		<field name="example_enable" type="radio" layout="joomla.form.field.radio.switcher" default="0" label="Enable">
			<option value="0">JNO</option>
			<option value="1">JYES</option>
		</field>
	</fieldset>
	<fieldset name="example_details" label="Details" showon="example_enable:1">
		<field name="example_text" type="text" label="Some Text" />
	</fieldset>
</fieldset>
  1. Go to System → Global Configuration → (component) → Options, and open the "Example" tab.
  2. Set "Enable" to No.

Expected result

The "Details" fieldset, including its legend, is hidden while "Enable" is No, and shown again when it is Yes.

Actual result

The "Details" fieldset stays visible whatever "Enable" is set to. The rendered <fieldset> element has no data-showon attribute.

Additional comments

administrator/components/com_config/tmpl/component/default.php already handles fieldset showon:

  • It builds $dataShowOn from $fieldSet->showon.
  • It loads the showon web asset.

But $dataShowOn is never echoed into either <fieldset> tag. showon.js picks up any element with data-showon, so printing the attribute is enough.

Proposed change (two lines in administrator/components/com_config/tmpl/component/default.php):

                     <?php if (!$isGrandchild && $hasParent) : ?>
-                        <fieldset id="fieldset-<?php echo $this->escape($name); ?>" class="options-menu options-form">
+                        <fieldset id="fieldset-<?php echo $this->escape($name); ?>" class="options-menu options-form"<?php echo $dataShowOn; ?>>
                             <legend><?php echo Text::_($fieldSet->label); ?></legend>
                         <?php if (!$hasChildren) : ?>
-                        <fieldset id="fieldset-<?php echo $this->escape($name); ?>" class="options-menu options-form">
+                        <fieldset id="fieldset-<?php echo $this->escape($name); ?>" class="options-menu options-form"<?php echo $dataShowOn; ?>>
                             <legend><?php echo Text::_($fieldSet->label); ?></legend>

Applying this locally fixed it. The child fieldset now hides and shows completely, legend included.

The current workaround is to put the same showon on every field inside the fieldset. That hides the fields, but the empty fieldset and its legend stay visible.

avatar Ruud68 Ruud68 - open - 26 Oct 2026
avatar Ruud68 Ruud68 - change - 26 Oct 2026
Labels Removed: ?
avatar joomla-cms-bot joomla-cms-bot - change - 26 Oct 2026
Labels Added: No Code Attached Yet
avatar joomla-cms-bot joomla-cms-bot - labeled - 26 Oct 2026
avatar brianteeman
brianteeman - comment - 1 Nov 2026

please test #48741

avatar Ruud68 Ruud68 - change - 2 Nov 2026
Status New ⇒ Closed
Closed_Date 0000-00-00 00:00:00 ⇒ 2026-11-02 15:56:50
Closed_By ⇒ Ruud68
avatar Ruud68 Ruud68 - close - 2 Nov 2026

Add a Comment

Login with GitHub to post a comment