Get Joomla Articles via Model inside static (Module) Method
Joomla Stack Exchange
by Marco
21h ago
When calling an AJAX Method in a Module Helper file the method has to be static. I have no app context there, when doing the following: public static function getDataAjax() { $data = ExampleHelper::getJArticles(); return $data; } public static function getJArticles(){ $app = Joomla\CMS\Factory::getApplication(); $model = $app->bootComponent('com_content')->getMVCFactory()->createModel('Articles', 'Site', ['ignore_request' => true]); $articles = $model->getItems(); return $articles; } An error 500 got thrown: Call to a ..read more
Visit website
Implementation of a tag in header of JoomGallery
Joomla Stack Exchange
by Clipart - Designer
4d ago
I would like to implement preload link into the head of the JoomGallery like <link as="image" href="image_name.png"> Unfortunatelly the following code does not work: <link as="image" href="<?php echo $this->image->img_src; ?>"> I assume the reason for it is not intialiasated object/not imported class within head. How can I develop it ..read more
Visit website
How to set root (/ and /de) as homepage in 2 menus?
Joomla Stack Exchange
by Destroy666
6d ago
While configuring other things I noticed that homepage is set to a "Featured articles" page in an invisible menu. Now I'm considering adding it to 2 visible menus in 2 languages. I'm not too sure what the best approach for this would be as setting "Featured articles" as homepage is extremely weird compared to e.g. Wordpress in the 1st place. Do I move the "Featured articles" entry to the displayed menu in 1 language, then add URL /de entry to the German one? Or is there an better practice for this in Joomla 4 I'm missing ..read more
Visit website
Upgrade to 4.4 - Ajax error / 90.2% completed
Joomla Stack Exchange
by kyle
6d ago
I am having a terrible time upgrading from 3.10.12 to 4.4 as well and received the same Ajax error / 90.2% completed, and then a bricked site that displays no content and has no admin login. I suspect I have an old template (3rd party, purchased from Crosstec), but it's not clear to me how to fix that. I suspect my extensions also need to be updated, but it doesn't seem like Joomla knows where to find them. The Update tab on the Extensions page says "There are no updates available at the moment." I have fixed the bricked site using Akeeba backup / drop databases a few times. I have used Akeeba ..read more
Visit website
Change Smart Search results template layout
Joomla Stack Exchange
by Destroy666
6d ago
I have 2 layouts in my template: default (which is indeed set as default) home For some reason Smart Search results use the home layout. How can I switch it to use default layout ..read more
Visit website
RSForm Modal form set value of dropdown on modal
Joomla Stack Exchange
by Ian
1w ago
I have an RSForm with a button to open a modal form using RSForm Plugin Modal. I wish to set the value of a dropdown on the modal form using jQuery. I do not know the id of the modal form that is created by the RSForm Plugin Modal, I think I need this to set the value of the DropDown I have obtained the data from a field on my main form using jQuery. var manufacturer = $("#ManufacturerDropDown").val(); } );``` I would like to pre-select a dropdown called "ManufacturerDropDown" in a form on the modal. As you may guess I'm only a numpty playing ar ..read more
Visit website
CSS changes with language - what could be possible causes?
Joomla Stack Exchange
by Destroy666
1w ago
I'm editing a website on Joomla 4.4.3 with someone's custom template, based on T4. I noticed that some of CSS is missing when I switch to German language. For example: @media (min-width: 992px) { .nav-breakpoint-lg.oc-desktop .t4-offcanvas-toggle { position: absolute; top: 50%; right: 0; margin-top: -12px; } } It is part of css/template.css file. I searched the entire template directory and didn't find any other references to that definition. I don't see any relation of CSS to language anywhere in the panel, Googling things like "Joomla language specific CSS" or "Joomla l ..read more
Visit website
Form Field Type to browse and select a file
Joomla Stack Exchange
by RogerCO
1w ago
I'm struggling with finding a good way to have a control (or controls) on a form which allow the user to browse and select a file in a folder tree. There may be several thousand files in several hundred folders (nested up to 4 levels deep). The best I can do is use the folderlist field (with recursive="true") and a separate filelist field (which only shows files in a single folder) but this is not very nice - when the folder selection changes it has to submit the form to refresh the filelist, and the user has to separately open the filelist to see the files in the folder. What I am after is so ..read more
Visit website
Joomla API returns 500 error, but works when debug is enabled
Joomla Stack Exchange
by AndyGaskell
1w ago
I'm using a very vanilla install of Joomla 5.1, and trying to use the content API. So a simple API call like... curl -X GET "https://example.com/api/index.php/v1/content/articles" \ -H "Content-Type: application/json" \ -H "Accept: application/vnd.api+json" \ -H "Authorization: Bearer $TOKEN" ...or even simpler, like... curl -X GET "https://example.com/api/index.php/v1/content/articles" -H "Authorization: Bearer $TOKEN" ...just returns... {"errors":{"code":500,"title":"Internal server error"}} ...but the strange thing is, it returns the correct article json if I set Jo ..read more
Visit website
DB Query with JOIN in Task Plugin
Joomla Stack Exchange
by Glenn Arkell
2w ago
I'm calling the following query to retrieve records and the primary table data elements are all included, but the JOIN elements of data are not included. Any suggestions what I'm missing? private function getRecordsOfMbrs($endDate) { $db = $this->getDatabase(); $query = $db->getQuery(true); $query->select(' a.*, b.title, b.term_type, b.term_dur, u.name, u.email ' ); $query->from($db->quoteName('#__mycomponent_records', 'a')); $query->join('LEFT', $db->quoteName('#__mycomponent_rectypes', 'b').' ON '.$db->quoteName('b.id').' = '.(int) $db->quot ..read more
Visit website

Follow Joomla Stack Exchange on FeedSpot

Continue with Google
Continue with Apple
OR