: str_replace(): Passing null to parameter #2 ($replace) of type array|string is deprecated in
define( 'HERALD_THEME_VERSION', '2.2.4' );
/* Define content width */
if ( !isset( $content_width ) ) {
load_theme_textdomain( 'herald', get_parent_theme_file_path( '/languages' ) );
/* After theme setup main hook */
add_action( 'after_setup_theme', 'herald_theme_setup' );
* Callback for after_theme_setup hook
function herald_theme_setup() {
/* Add thumbnails support */
add_theme_support( 'post-thumbnails' );
/* Add theme support for title tag (since wp 4.1) */
add_theme_support( 'title-tag' );
$image_sizes = herald_get_image_sizes();
if ( !empty( $image_sizes ) ) {
foreach ( $image_sizes as $id => $size ) {
add_image_size( $id, $size['args']['w'], $size['args']['h'], $size['args']['crop'] );
/* Add post formats support */
add_theme_support( 'post-formats', array(
'audio', 'gallery', 'image', 'video'
add_theme_support( 'html5', array( 'comment-list', 'comment-form', 'search-form', 'gallery', 'caption' ) );
/* Automatic Feed Links */
add_theme_support( 'automatic-feed-links' );
/* Declare WooCommerce support */
add_theme_support( 'woocommerce' );
add_theme_support( 'wc-product-gallery-zoom' );
add_theme_support( 'wc-product-gallery-lightbox' );
add_theme_support( 'wc-product-gallery-slider' );
add_theme_support( 'editor-styles' );
herald_load_editor_styles();
/* Support for alignwide elements */
add_theme_support( 'align-wide' );
/* Support for responsive embeds */
add_theme_support( 'responsive-embeds' );
/* Support for predefined colors in editor */
add_theme_support( 'editor-color-palette', herald_get_editor_colors() );
/* Support for predefined font-sizes in editor */
add_theme_support( 'editor-font-sizes', herald_get_editor_font_sizes() );
/* Load frontend scripts */
include_once get_parent_theme_file_path( '/core/enqueue.php' );
/* Helpers and utility functions */
include_once get_parent_theme_file_path( '/core/helpers.php' );
include_once get_parent_theme_file_path( '/core/default-options.php' );
/* Module-specific functions */
include_once get_parent_theme_file_path( '/core/modules.php' );
include_once get_parent_theme_file_path( '/core/template-functions.php' );
include_once get_parent_theme_file_path( '/core/menus.php' );
include_once get_parent_theme_file_path( '/core/sidebars.php' );
/* Extensions (hooks and filters to add/modify specific features ) */
include_once get_parent_theme_file_path( '/core/extensions.php' );
/* Add support for our mega menu */
include_once get_parent_theme_file_path( '/core/mega-menu.php' );
/* Admin helpers and utility functions */
include_once get_parent_theme_file_path( '/core/admin/helpers.php' );
include_once get_parent_theme_file_path( '/core/admin/enqueue.php' );
include_once get_parent_theme_file_path( '/core/admin/options.php' );
/* Include plugins - TGM Init */
include_once get_parent_theme_file_path( '/core/admin/plugins.php' );
/* Include AJAX action handlers */
include_once get_parent_theme_file_path( '/core/admin/ajax.php' );
/* Extensions ( hooks and filters to add/modify specific features ) */
include_once get_parent_theme_file_path( '/core/admin/extensions.php' );
include_once get_parent_theme_file_path( '/core/admin/metaboxes.php' );
/* Demo importer panel */
include_once get_parent_theme_file_path( '/core/admin/demo-importer.php' );