Special Sale! Get all our extensions, templates and training for under $100!  Sale ends in
Joomlashack

You Now Safely Create Custom Template Overrides in Wright

Custom Template Overrides in Wright

Starting in Wright 3.6, you can safely add custom template overrides to the Wright base template and our commercial templates

This will make possible to tweak the templates without touching the core Wright files, and protect your changes for future Wright updates.

How to create a custom template override in Wright

Depending what extension you want to override (as example, the design for articles component means you would override /com_content/), please check in /templates/js_wright/html/ if the folder for that extension actually exist. If exists, don't place your override inside /html/ folder, do it instead inside /templates/js_wright/overrides/joomla_3.0/.

In this example the path would be /templates/js_wright/overrides/joomla_3.0/com_content/.

extensions3

This is a slight different approach to native template overrides that live in html folder. The custom overrides in Wright works in same way, just the location is different.

Which template overrides are supported

All the common templates overrides are supported. The custom overrides should be done depending the case as explained in coming lines.

To avoid losing your customizations in every new Wright update, we highly recommend you to add your own overrides through /templates/js_wright/overrides/joomla_3.0/ folder for the components and modules listed below:

extensions1

You can also do overrides for these layouts:

extensions2

If the component, module or layout file doesn't exist inside /templates/js_wright/html/ folder, then you need to place two files:

  • One inside /templates/js_wright/overrides/joomla_3.0/ - Here you place your custom design.
  • Place a regular override in /templates/js_wright/html/ - Here you place the code below to point to your final override replacing /path/to/custom/file.php with your own.

<?php
defined('_JEXEC') or die;

$app = JFactory::getApplication();
require_once(JPATH_THEMES.'/'.$app->getTemplate().'/overrides/joomla_3.0/path/to/custom/file.php');
?>

As example, if you override the tags.php layout from /layouts/joomla/content/tags.php, you would place the code below in /templates/js_wright/html/layouts/joomla/content/tags.php

<?php
defined('_JEXEC') or die;

$app = JFactory::getApplication();
require_once(JPATH_THEMES.'/'.$app->getTemplate().'/overrides/joomla_3.0/joomla/content/tags.php');
?>

 

 

 

Since 2005, Joomlashack has been a leading supplier of free and commercial Joomla templates, Joomla extensions, and Joomla Training.
Joomlashack.com is not affiliated with or endorsed by the Joomla! Project or Open Source Matters.
The Joomla! name and logo is used under a limited license granted by Open Source Matters the trademark holder in the United States and other countries.