12% off of LTD using this coupon: TWELVEPERCENTOFF. Promo ends on 2 Dec midnight UTC.
Published on May 7, 2020

Overriding Plugin Templates in Oxygen

Sridhar Katakam

Oxygen‘s biggest strength – namely disabling the active theme is also its biggest weakness.

Oxygen has truly one and only one limitation technically speaking – not being able to override templates of other plugins because there is no working active theme.

Thankfully some popular plugin developers offer a way (a filter hook) to change the location at which their plugin’s templates can be overridden which means those templates can be copied to a functionality plugin and modified as needed.

Below are links to tutorials/resources for some of them:

If you come across a plugin you want to override the templates of, check its documentation for a filter to change the template overrides location or contact the plugin author.

Below is a sample email template that you could modify and send to the plugin developer requesting him/them to provide a filter using which it will be possible to override plugin’s templates from within a custom functionality plugin:

Hello,

I would like to override your plugin’s templates by following < https://strongtestimonials.com/docs/customizations/custom-templates/initial-steps/ > (replace this with the corresponding URL from the plugin documentation).

I use Oxygen which disables themes.

I am wondering if there is a filter to change the plugin template override path so I can override your plugin’s templates from within a custom functionality plugin?

Others like WooCommerce (woocommerce_locate_template), EDD (edd_template_paths) and RCP (rcp_template_stack) provide them.

Examples:

https://wpdevdesign.com/how-to-override-woocommerce-templates-using-a-custom-functionality-plugin/

https://github.com/wplit/Oxygen-EDD-Support/blob/master/plugin.php

https://github.com/wplit/Oxygen-RCP-Support/blob/master/plugin.php

Thanks for your help.

tagschevron-leftchevron-rightchainangle-rightangle-upangle-downfolder-omagnifiercrossmenuchevron-downarrow-right