7 votes

Joomla constant to current template path

Look at https://gist.github.com/leFlea-snippets/4602845 PHP: Joomla - Get active template path // Get active template path from anywhere on Joomla: $app = JFactory::getApplication(); $path = ...
Cravener's user avatar
6 votes
Accepted

Update Server for template

I think the article is not up-to-date because update server is working properly with template. Here's the code I use in the templateDetails.xml <updateservers> <server type="extension" ...
webchun's user avatar
  • 2,418
6 votes
Accepted

How to get ALL params of object?

You can simply use the following: $componentParams= JComponentHelper::getParams('com_content'); var_dump($componentParams); This will provide an object like so: object(Joomla\Registry\Registry)[...
Lodder's user avatar
  • 26.8k
4 votes
Accepted

Range form field type

When ever in doubt about Joomla's form fields, have a look at the following directory, where you will find each one. libraries/joomla/form/fields To get a range form field, you can use the ...
Lodder's user avatar
  • 26.8k
3 votes
Accepted

Creating a module and giving it config parameters options

Welcome to JSE. I'm not sure which documentation you've been referring to, however the Joomla Docs show you how to add parameters to your module: https://docs.joomla.org/J3.x:...
Lodder's user avatar
  • 26.8k
3 votes
Accepted

Module Template/alternate layout Name language Override

The layout language key is built like this: $key = strtoupper($module . '_LAYOUT_' . $value); Where $module is the module name (including mod_ prefix) and $value is the layout name. Example string ...
Sharky's user avatar
  • 10.5k
3 votes

How to change form values sent by a module?

If you're talking about module definition file that holds module options you can't do much in the file using framework it-self. But you can do it in 3 other ways. In the UI by Java Script Just create ...
Artur Stępień's user avatar
3 votes
Accepted

Custom field colResizable plugin not working but works in fiddle

You are calling the colResizable jQuery plugin before the jQuery itself. It should be the other way round. Also, Joomla's admin should also already have jQuery loaded, but that uses jQuery v1.12.4. ...
RichardB's user avatar
  • 3,072
3 votes

Show 'menuitem' field name in frontend of module

You can use the following: $menu = Joomla\CMS\Factory::getApplication()->getMenu(); $menuItem = $menu->getItem($menulink); echo $menuItem->title; If you var_dump($menuItem);, it will show ...
Lodder's user avatar
  • 26.8k
2 votes

Reset button for template parameters

Template style options are saved in #__template_styles.params. A Protostar's sample saved params: {"templateColor":"#696969","templateBackgroundColor":"#E3E3E3","logoFile":"","googleFont":"1","...
FFrewin's user avatar
  • 19.6k
2 votes
Accepted

How to add attribute to <form> of backend for module

The short answer is there's an "easier" way. The assumption being you need to provide a means for a user to upload a file as part of the core configuration of the module. Since there isn't a ...
Brian Bolli's user avatar
  • 1,416
2 votes

Custom field colResizable plugin not working but works in fiddle

How about to change the $ sign with jQuery? So the code would be jQuery("#tableResizable").colResizable({ fixed:true, liveDrag:true, gripInnerHtml:"<div class='grip'>&...
webchun's user avatar
  • 2,418
2 votes
Accepted

Move the Joomla! module layout override to a different tab

I am losing you a little bit in your question. Saying move the Joomla module layout override option, do you mean to display that field within another tab? If so, what's the problem you are facing ...
FFrewin's user avatar
  • 19.6k
2 votes

XML file does not upload with my custom module

The manifest (main xml) is the only file that doesn't need to be included in the manifest (ie itself). Other xml files need to be listed either as files or be in listed folders. One attribute in the ...
jamesgarrett's user avatar
  • 3,279
2 votes
Accepted

Joomla 3 - How to set module params programmatically?

Yes you can save the params of the module programmatically by taking the instance of the extension table 1: JTable update $table = JTable::getInstance('extension'); $table->load($moduleId); $...
Pratyush's user avatar
  • 496
2 votes

Can't pass params to external php file

By looking at updated xml file, I see only one issue that you haven't used <fields name="params"></fields> in config tag and hence your modparams object showing blank. Try below xml ...
Sudhir Sapkal's user avatar
2 votes
Accepted

<customContent /> or <field type="editor">

Well, I've just had my first case when using one or the other seems relevant. In the database, Joomla's fields for both the "params" and the "content" fields of modules are of the type TEXT, which ...
RichardB's user avatar
  • 3,072
2 votes

<customContent /> or <field type="editor">

I've tried doing some research on this of my own as I was interested to see what purpose it served. Looking through some Github issues, it has been noted that customContent is valid, however ...
Lodder's user avatar
  • 26.8k
2 votes
Accepted

Joomla 4 - Module Backend Subform subform-row-add "row" not available

The way the event is invoked is slightly different for Joomla 4. You can use the following: $(document).on('subform-row-add', function(event) { console.log(event.detail.row); }); Or native ES6+ ...
Lodder's user avatar
  • 26.8k
2 votes
Accepted

subform inside subform in module

Access the link fields the same way you're accessing other fields, through the main activities field. <?php foreach ((array) $activities as $activity) : ?> <?php foreach ((array) $...
Sharky's user avatar
  • 10.5k
2 votes

Use different module settings/parameters on different posts in Joomla!

Joomla's design allows you to have multiple instances of modules to allow you to undertake what you've explained you're trying to do. Basic Implementation The assignments tab in the module settings ...
Patrick Jackson's user avatar
2 votes
Accepted

ModuleHelper::renderModule with custom parameters

Attributes aren't meant to be used inside module context and they're no longer passed there. They're now only available in module chromes. Short of stuffing properties into $module object there isn't ...
Sharky's user avatar
  • 10.5k
1 vote
Accepted

Show article details from custom module

As far as I know, the SQL form field will always return the ID of an article. So you can get the title, into text and intro image, you can use Joomla's Table class: use Joomla\CMS\Table\Table; $...
Lodder's user avatar
  • 26.8k
1 vote
Accepted

Get module params in custom form field

Get the value from current form. $bgcolor = $this->form->getField('bgcolor', 'params')->value;
Sharky's user avatar
  • 10.5k
1 vote

Module field type category not working

Joomshopping may have categories for the products, but it does not the Joomla core categories table/model for its categories. It has its own. The categories field is for the Joomla core categories, ...
FFrewin's user avatar
  • 19.6k
1 vote

How to add article links to module mod_articles_category?

Create an override for the module in templates/your_template/html/mod_articles_category/default.php Add to the line 20 and 84 after li tag: <?php $params = $item->params; $urls = ...
Dennis Heiden's user avatar
1 vote
Accepted

Joomla 3.6 nested subforms not saving

So far this is not yet possible to do in Joomla. Nested subforms or in other words multi level subforms is on the agenda. It's just hoping a good volunteer is ready to tacke this issue. More info can ...
purple11111's user avatar
1 vote
Accepted

use Joomla Subform field values in custom field from same module

I solved this doing it a bit different. B is done via this code which grabs all the inputs and converts them to a select box. Then when the user makes a selection it copies that selection to a normal ...
purple11111's user avatar
1 vote
Accepted

How to connect to DB in module's admin panel

For this, you can go with a custom form field type In your form field, you can interact the way you want with the database and have your results printed in the module's admin panel. Perhaps you ...
FFrewin's user avatar
  • 19.6k
1 vote
Accepted

Module Development: What fieldset name do I need to use to add JFields to the tabs: Menu Assignment & Module Permissions

Unfortunately you can not add custom fields to "Menu assignment" & "Module Permissions" tabs, because these are only for core features. You have three options: Module tab <fieldset name="...
Rene Korss's user avatar
  • 3,208

Only top scored, non community-wiki answers of a minimum length are eligible