Site logo

Archived topic

Adding filter in the functions file

1 reply · Started by marc on November 2, 2022

Viewing posts 1–2 of 2

Hey guys,

Apologies for the trouble, I'm trying to add a filter for in the functions file of GP and wanted to know if I absolutely had to install a child theme.

I have 2 plugin conflicting with one another and I'd like to add the following filter not using a child theme considering it's a big site and I'm scared to break something. Would it be possible to add the following filter using the code snippets plugin?

Here is the filter I'm trying to add:

$content = apply_filters('ilj_get_the_content', get_the_content());
$content = apply_filters( 'the_content', $content);
echo $content;

--
Thanks in advance for your help

Hi Marc,

For context, may we know what you're trying to achieve?

By the looks of it, that code is meant to modify a template file, so, you'll need to use the Child theme if so.

Let us know.

This archived topic is closed to new replies.