2

Create a installer script for your component (com_your_component_name/script.php) and add the following code: <?php defined('_JEXEC') or die; class com_your_component_nameInstallerScript { function update($parent) { JFile::delete($path.$file) } } The installer script file allows you to run code when your component is installed, uninstalled, ...


2

For the purpose you are describing, your best bet is to create your own Joomla custom library. It's a type of Joomla extension alongside with plugins, modules and components, allowing you to put your custom common code. There is not much examples in Joomla documentation but Roberto Segura (phproberto) made an awesome example of a custom library available on ...


2

You could try the "spacer" field type and see if that's good enough for your purposes: <field name="example_spacer" type="spacer" label="Text you want here" /> Then put it in your XML file following the field you're wanting the extra text for. Add CSS to taste. That might work out for you.


2

Your component has a manifest file (component_name.xml). In that file you list the files you want the installer to upload and locate. So you create a section that looks something like this: <media destination="com_whatever" folder="media"> <folder>js</folder> </media> That tells the installer to install the folder 'js' into /media/...


2

The Problem is the SEF Plugin. So I don't want to modify a core Plugin, so I wrote a new Plugin that makes the changes only for the mustache template back. !!! Importent that the new plugin must execute after the SEF Plugin Here is my code sample to replace the / for the {{name}} public function onAfterRender() { if (!$this->app->...


2

In your index.php, you can use the following: <?php $menu = JFactory::getApplication()->getMenu(); ?> <?php if ($menu->getActive() != $menu->getDefault()) : ?> <jdoc:include type="component" /> <?php endif; ?> All this basically does is check if the active menu item doesn't match the default menu item. If it doesn't, ...


2

I had the same problem on twitter. I was trying to add my link picture just as facebook does automatically but had to investigate the CARD Validator here https://cards-dev.twitter.com/validator ...Tthe way I have it working on Joomla 3.9.11 is adding this code in the head of my template default.php ... I was able to properly add the title, the description ...


1

JHtmlSidebar is pretty simple and doesn't support headings/separators or anything like that. But you can fake them by adding the required HTML to the language string used as a name for the entry and omitting the link. The language string: COM_MYCOMPONENT_SUBMENU_HEADING="<h3>My Heading</h3>" COM_MYCOMPONENT_SUBMENU_SEPARATOR="<span class=\"...


1

Looks like the variable $params isn't getting set. Could be several reasons this is happening, among them that there isn't a menu item set in the current URL. As @lodder noted, this is old code. The mechanism involving the static call of getMenu from the site application was deprecated years ago; nobody should be using it anymore. (Don't remember precisely ...


1

Website visitors can be directed to a maintenance page at index.html or index.htm rather than any kickstart.php or index.php file as most hosts are configured to load index.html or index.htm in preference to index.php. You can ensure this is the case by adding the following directive to your .htaccess file: DirectoryIndex index.html index.htm index.php It ...


1

To answer the question about what is core and what isn't when you look at the extensions under the Extensions->Manage->Manage menu look at the ID column on the far right and if the ID is less than 999(or only has three digits) then it is core, if it above 10000 then it is 3rd party. If the site has been progressively migrated from early versions of Joomla ...


1

Any layout or view can be overridden in Joomla. You can do this in your Joomla admin panel, by going to: Extensions (top menu) >> Templates >> Templates >> Details and Files Once there, go to the "Create Overrides" tab, and you will be able to select your component annd the view. So let's say you create an override for com_content/archive. This will ...


1

The problem was solved by adding the JHtml::_('behavior.framework'); directive in the view so that the problem of: ReferenceError: Joomla is not defined that occurred when you clicked on any of the pages of the pager component The final code is <?php defined('_JEXEC') or die('Restricted access'); class DemoViewDemo extends JViewLegacy { public ...


1

Looking at how Weblinks works I can see that the only time weblinks.go gets involved is when you have have an option selected to count Hits for each link causing view.html.php to display this style of link: $item->link = JRoute::_('index.php?option=com_weblinks&task=weblink.go&id=' . $item->id); at line 88 of default_items.php I would ...


1

From your question it is ambiguous whether your entry file is inside the admin subfolder or not. It should be in the com_administratie folder if it isn't. Also your xml files declaration looks odd: <files folder="components/com_administratie/admin"> <file>administratie.php</file> </files> The folder attribute should just be site ...


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