?
avatar sandewt
sandewt
30 Jul 2021

Steps to reproduce the issue

Try to add the module class suffix to the modules (backend and frontend).

Expected result

Can add the module class suffix.

Actual result

Unable to add the module class suffix.

System information (as much as possible)

Joomla 4

Additional comments

Missing of:
$moduleclass_sfx = htmlspecialchars($params->get('moduleclass_sfx'), ENT_COMPAT, 'UTF-8');

class="mod-custom custom<?php echo $moduleclass_sfx; ?>

avatar sandewt sandewt - open - 30 Jul 2021
avatar joomla-cms-bot joomla-cms-bot - labeled - 30 Jul 2021
avatar Fedik
Fedik - comment - 30 Jul 2021

It exists in module chrome /layouts/chromes

$moduleAttribs['class'] = 'moduletable ' . htmlspecialchars($params->get('moduleclass_sfx'), ENT_QUOTES, 'UTF-8');

avatar richard67
richard67 - comment - 30 Jul 2021

Beside that, as far as I remember in J4 the module class suffix is not a suffix anymore which is appended to the class, it is a module class which is added to the class, separated with a space.

avatar chmst
chmst - comment - 30 Jul 2021

correct ... the name of the variable needs to be changed.

avatar sandewt
sandewt - comment - 30 Jul 2021

A closer look, shows that the issue occurs in the position menu and not in the position sitebar-right for example.


This comment was created with the J!Tracker Application at issues.joomla.org/tracker/joomla-cms/34982.

avatar sandewt
sandewt - comment - 30 Jul 2021

I have used the module mod_custom.

34982

avatar brianteeman
brianteeman - comment - 30 Jul 2021

As already stated by @Fedik the suffix is applied by the chrome.

If you look at the template you will see that the menu position has no chrome

<jdoc:include type="modules" name="menu" style="none" />

So thats the explanation and the solution for you would be to change the style="none" to style="html5" in the templates index.php

OR

In the module settings change the style from inherited to html5 (or any other chrome that uses the suffux)

image

avatar richard67
richard67 - comment - 30 Jul 2021

@sandewt Is the explanation above sufficient for you? If so, please close this issue. From my point of view it is expected behaviour.

avatar sandewt sandewt - change - 30 Jul 2021
Status New Closed
Closed_Date 0000-00-00 00:00:00 2021-07-30 11:18:03
Closed_By sandewt
avatar sandewt sandewt - close - 30 Jul 2021
avatar sandewt
sandewt - comment - 30 Jul 2021

@sandewt Is the explanation above sufficient for you? If so, please close this issue. From my point of view it is expected behaviour.

Yes

avatar sandewt
sandewt - comment - 30 Jul 2021

Thanks all

avatar brianteeman
brianteeman - comment - 30 Jul 2021

Just want to repeat that this expected behaviour is for me not a good behaviour and I have brought this up before. From my perspective every default setting in a module should function in every module chrome.

avatar sandewt
sandewt - comment - 30 Jul 2021

Just want to repeat that this expected behaviour is for me not a good behaviour...

Indeed, inconsistent behavior creates confusion. In joomla 3 the top position was included.

avatar Fedik
Fedik - comment - 30 Jul 2021

In joomla 3 it is duplicated if module chrome is used,
that makes another issue

Add a Comment

Login with GitHub to post a comment