FTP

The layout files are used by the component to generate the same HTML blocks on different sections of the program or maybe on those parts that cannot be overridden, such as an AJAX task placed within the controller.

Before all it is needed to keep/download a copy of the layout file to override. For example, we can download that file by reaching it via FTP. The path to reach will be something like:

/components/COMPONENT_NAME/layouts/FOLDER_NAME/LAYOUT_NAME.php

Once the layout file has been downloaded, it is needed to upload it onto the overrides folder of your template, for example via FTP. The resulting path will be structured as follows:

/YOUR_TEMPLATE/html/layouts/COMPONENT_NAME/FOLDER_NAME/LAYOUT_NAME.php

At this point it is possible to edit this new layout file in order to change the way it is displayed.

Template Manager

As of Joomla 3.2 the overrides can be created using the Template Manager.

The following example steps explains how to override the com_users > login view.

  1. Before all it is needed to open the back-end of your Joomla! and access the Extensions > Templates > Templates page from the main menu.
  2. Click the name of your active template in order to access its File Manager.
  3. Access the section called Create Overrides simply by clicking the related tab button.
  4. Click the com_users item under the Components column to expand the list containing all the views that belong to this component. Then, click the login element to generate the override files for this view.
  5. After generating the override, you will be pushed back to the File Manager home page, from which you can access the files to edit. The files can be found under html > com_users > login folder. As you can see, this folder contains all the files (not only one) needed to complete the layout of the view. By clicking, for example, the default.php file, the system will load it into the code editor, ready to be customized.
Last Update: 2019-04-29 09:57
Helpful?
This site uses cookies. By continuing to browse you accept their use. Further information