Using Filters

GeneratePress uses the WordPress Filter API to add filters throughout the theme

Filters allow you to use a simple function to overwrite values, whether they’re options or even text on your site.

To view the available filters, please refer to the Filters collection.


add_filter( 'filter_name', 'example_function_name' );
function example_function_name()
    return 'Your new value';

In the example above, replace filter_name with the name of the filter you’re wanting to use, like generate_404_title or generate_sidebar_layout.

Then replace example_function_name with a unique function name, something specific to you. My name is Tom Usborne, so I would prefix my function like this for example: tu_change_404_title

Learn how to add PHP here.