1 || preg_match( "/(Trident\/(\d{2,}|7|8|9)(.*)rv:(\d{2,}))|(MSIE\ (\d{2,}|8|9)(.*)Tablet\ PC)|(Trident\/(\d{2,}|7|8|9))/", $_SERVER["HTTP_USER_AGENT"], $match ) !== 0 ) { return get_template_directory() . '/internet-explorer.php'; } return null; } add_action( 'dynamic_sidebar_before', function () { ob_start(); } ); add_action( 'dynamic_sidebar_after', function () { $text = str_replace( 'textwidget', 'textwidget entry-content', ob_get_clean() ); echo $text; } ); function blocksy_body_attr() { return blocksy_attr_to_html(array_merge([ 'data-link' => get_theme_mod('content_link_type', 'type-1') ], blocksy_schema_org_definitions('single', ['array' => true]))); } function blocksy_locate_theme_path($rel_path) { if (is_child_theme() && file_exists(get_stylesheet_directory() . $rel_path)) { return get_stylesheet_directory() . $rel_path; } elseif (file_exists(get_template_directory() . $rel_path)) { return get_template_directory() . $rel_path; } else { return false; } } function blocksy_assert_args($args, $fields = []) { foreach ($fields as $single_field) { if ( ! isset($args[$single_field]) || !$args[$single_field] ) { throw new Error($single_field . ' missing in args!'); } } } add_filter('widget_nav_menu_args', function ($nav_menu_args, $nav_menu, $args, $instance) { $nav_menu_args['menu_class'] = 'widget-menu'; return $nav_menu_args; }, 10, 4); class Blocksy_Walker_Page extends Walker_Page { public function start_lvl( &$output, $depth = 0, $args = array() ) { if ( isset( $args['item_spacing'] ) && 'preserve' === $args['item_spacing'] ) { $t = "\t"; $n = "\n"; } else { $t = ''; $n = ''; } $indent = str_repeat( $t, $depth ); $output .= "{$n}{$indent}
'; // phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped echo htmlspecialchars( Blocksy_FW_Dumper::dump( $value ) ); echo '
* echo TVar_dumper::dump($var);
*
*
* @author Qiang Xue