News:

Dear forum visitors, if the support forum is not available, please try again a few minutes later. Thanks!

Main Menu
Support-Forum

Accessing System_Text from JDownloads Latest Module

Started by mhoney, 15.05.2020 18:05:24

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

mhoney

I would like to access the System.List from the JDownloads Latest module so I can add the system_text information to the newest downloads.  I found the code that does that for the Download Details but don't know how to add it to the Latest module, I'm not much of a programmer.

Here is the code I'd like to get working:

// set system value
        $this->item_sys_values = explode(',' , JDHelper::getOnlyLanguageSubstring($jlistConfig['system.list']));
        if ($this->item->system == 0 ) {
             $body = str_replace('{system_text}', '', $body);
        } else {
             $body = str_replace('{system_text}', $this->item_sys_values[$this->item->system], $body);
        }


When I try to use this to get the system_text I get an error about JDHelper not being found.

  •  

ColinM

HiIn general the layout 'placeholders' such as {system_text} are not available in jD modules.  It would be a useful addition to provide one or two such place holders - so need to make this a suggestion.
Note If you add special code it will be overwritten on the next upodate unless you use an override
Colin
Colin M
  •