esc_html__('Contact Form 7','rambo'), 'slug' => 'contact-form-7', 'required' => false ), array( 'name' => esc_html__('Webriti Companion','rambo'), 'slug' => 'webriti-companion', 'required' => false ), array( 'name' => esc_html__('Social Media Icons Widget','rambo'), 'slug' => 'spoontalk-social-media-icons-widget', 'required' => false ) ); /* * Array of configuration settings. Amend each line as needed. * * TGMPA will start providing localized text strings soon. If you already have translations of our standard * strings available, please help us make TGMPA even better by giving us access to these translations or by * sending in a pull-request with .po file(s) with the translations. * * Only uncomment the strings in the config array if you want to customize the strings. */ $config = array( 'id' => 'tgmpa', // Unique ID for hashing notices for multiple instances of TGMPA. 'default_path' => '', // Default absolute path to bundled plugins. 'menu' => 'tgmpa-install-plugins', // Menu slug. 'has_notices' => true, // Show admin notices or not. 'dismissable' => true, // If false, a user cannot dismiss the nag message. 'dismiss_msg' => '', // If 'dismissable' is false, this message will be output at top of nag. 'is_automatic' => false, // Automatically activate plugins after installation or not. 'message' => '', // Message to output right before the plugins table. ); tgmpa( $plugins, $config ); } global $resetno; //user for reset function //wp title tag starts here function rambo_head( $title, $sep ) { global $paged, $page; if ( is_feed() ) return $title; // Add the site name. $title .= esc_html(get_bloginfo( 'name' )); // Add the site description for the home/front page. $site_description = esc_html(get_bloginfo( 'description' )); if ( $site_description && ( is_home() || is_front_page() ) ) $title = "$title $sep $site_description"; // Add a page number if necessary. if ( $paged >= 2 || $page >= 2 ) $title = "$title $sep " . sprintf( esc_html_e('Page','rambo'), max( $paged, $page ) ); return $title; } add_filter( 'wp_title', 'rambo_head', 10,2 ); function rambo_customizer_css() { wp_enqueue_style( 'rambo-customizer-info', RAMBO_TEMPLATE_DIR_URI . '/css/pro-feature.css' ); } add_action( 'admin_init', 'rambo_customizer_css' ); add_action( 'after_setup_theme', 'rambo_setup' ); function rambo_setup() { // Load text domain for translation-ready load_theme_textdomain( 'rambo', RAMBO_TEMPLATE_DIR . '/languages' ); add_theme_support( 'post-thumbnails' ); //supports featured image add_theme_support( 'woocommerce' );//woocommerce add_theme_support( 'title-tag' ); //Title Tag add_theme_support( 'automatic-feed-links' ); // Feed Link add_theme_support( 'custom-background' ); // Custom Background // Add theme support for selective refresh for widgets. add_theme_support( 'customize-selective-refresh-widgets' ); add_editor_style(); //Custom logo add_theme_support( 'custom-logo' , array( 'class' => 'navbar-brand', 'width' => 300, 'height' => 50, 'flex-width' => false, 'flex-height' => false, 'header-text' => array( 'site-title', 'site-description' ), ) ); // This theme uses wp_nav_menu() in one location. register_nav_menu( 'primary', esc_html__( 'Primary Menu', 'rambo' ) ); // setup admin pannel defual data for index page $rambo_theme=rambo_theme_data_setup(); //About Theme $theme = wp_get_theme(); // gets the current theme if ('Rambo' == $theme->name) { if (is_admin()) { require get_template_directory() . '/admin/admin-init.php'; } } //content width if ( ! isset( $content_width ) ) { $content_width = 900; } } // change custom logo link class add_filter('get_custom_logo','rambo_change_logo_class'); function rambo_change_logo_class($html) { $html = str_replace('class="custom-logo-link"', 'class="brand"', $html); return $html; } //Cerate enwueu function in customizer setting function rambo_customize_preview_js() { wp_enqueue_script( 'rambo-customize-preview', get_template_directory_uri() . '/js/customize-preview.js', array( 'customize-preview' ), '20160816', true ); } add_action( 'customize_preview_init', 'rambo_customize_preview_js' ); if ( ! function_exists( 'wp_body_open' ) ) { function wp_body_open() { /** * Triggered after the opening tag. */ do_action( 'wp_body_open' ); } } function rambo_hide_page_title() { if( !is_shop() ) // is_shop is the conditional tag return true; } add_filter( 'woocommerce_show_page_title', 'rambo_hide_page_title' ); /** * Fix skip link focus in IE11. * * This does not enqueue the script because it is tiny and because it is only for IE11, * thus it does not warrant having an entire dedicated blocking script being loaded. * * @link https://git.io/vWdr2 */ function rambo_skip_link_focus_fix() { // The following is minified via `terser --compress --mangle -- js/skip-link-focus-fix.js`. ?>