For developers

Custom templates

You can add to your theme unique templates for the Content Egg plugin.

pageCustom templates

Front search customization

pageFrontend Search



Access to data

add_action('content_egg_save_data', 'my_function', 13, 4);

Hook is called every time after saving/updating data of the Content Egg plugin.


$data - (array) Data array.

$module_id - (string) Module ID.

$post_id - (int) Post ID.

$is_last_iteration - (bool) Is this the last iteration or will there be other modules that need to save the data right now?

add_action('cegg_autoblog_post_create', 'my_function', 10, 1);

Hook is called every time after creating the post by autoblog


$post_id - (int) Post ID.

The Content Egg data is stored in standard Custom fields of Wordpress. In your theme or plugin you can get an access to the raw data of each module:

get_post_meta($post_id, '_cegg_data_'. $module_id, true);

The recommended way to get the Content Egg data, after processing for display on the site:

\ContentEgg\application\components\ContentManager::getViewData($module_id, $post_id);

Available filters

Templates for modules might be stored in theme directory. Thus you can create theme with the special number of Content Egg templates. And, maybe, you will want to disable some or all standard Content Egg templates. Use the filter to do this:

add_filter('content_egg_module_templates', 'my_filter_function');

The first parameter will be array of templates list, the second – module title.

For block templates:

add_filter('content_egg_block_templates', 'my_filter_function');

Also you can disable some modules:

add_filter('content_egg_modules', 'my_filter_function');

Use these features carefully, explain to the user why some standard plugin features are disabled.

If you are the author of a theme or a plugin, and you have any questions or proposes, please apply to our support.

Last updated