?
avatar brianteeman
brianteeman
4 Sep 2017

In the #__extensions table check the content of the params field for the com_modules extension

You will see that the content is something like

{"redirect_edit":"site","adminlangfilter":1}

Looking at the content of other fields there are missing quotes and it should look like

{"redirect_edit":"site","adminlangfilter":"1"}

Not sure though - please advise

avatar brianteeman brianteeman - open - 4 Sep 2017
avatar joomla-cms-bot joomla-cms-bot - change - 4 Sep 2017
Labels Added: ?
avatar joomla-cms-bot joomla-cms-bot - labeled - 4 Sep 2017
avatar infograf768
infograf768 - comment - 4 Sep 2017

This is due to the filter="integer" in the field

		<field
			name="adminlangfilter"
			type="radio"
			label="COM_MODULES_ADMIN_LANG_FILTER_LABEL"
			description="COM_MODULES_ADMIN_LANG_FILTER_DESC"
			class="btn-group btn-group-yesno"
			default="0"
			filter="integer"
			>
			<option value="1">JYES</option>
			<option value="0">JNO</option>
		</field>

It is indeed not necessary here but no undesired consequences as the param works whether the filter is set or not.

avatar brianteeman
brianteeman - comment - 4 Sep 2017

OK - thanks for confirming - it looked odd so I thought I should check

avatar brianteeman brianteeman - change - 4 Sep 2017
Status New Closed
Closed_Date 0000-00-00 00:00:00 2017-09-04 07:34:52
Closed_By brianteeman
avatar brianteeman brianteeman - close - 4 Sep 2017
avatar SharkyKZ
SharkyKZ - comment - 4 Sep 2017

Integers shouldn't be wrapped in quotes in JSON. It would be a good practice to add integer filter on all fields like this.

avatar infograf768
infograf768 - comment - 4 Sep 2017

@SharkyKZ
Would be a good new PR as we have multiple occurences of this in core.

Add a Comment

Login with GitHub to post a comment