<?php
	if ( ! function_exists( 'diner_restaurant_setup' ) ) :

	function diner_restaurant_setup() {
		$GLOBALS['content_width'] = apply_filters( 'diner_restaurant_content_width', 640 );
		
		add_theme_support( 'automatic-feed-links' );
		add_theme_support( 'woocommerce' );
		add_theme_support( 'wc-product-gallery-zoom' );
		add_theme_support( 'wc-product-gallery-slider' );
		add_theme_support( 'wc-product-gallery-lightbox' );
		add_theme_support( 'post-thumbnails' );
		add_theme_support( 'title-tag' );
		add_theme_support( 'align-wide' );
		add_theme_support( 'wp-block-styles' );
		add_theme_support( 'responsive-embeds' );
		add_theme_support( 'html5', array( 'comment-list', 'search-form', 'comment-form', ) );
		add_theme_support( 'custom-logo', array(
			'height'      => 240,
			'width'       => 240,
			'flex-height' => true,
		) );

		add_theme_support( 'custom-background', array(
			'default-color' => 'f1f1f1'
		) );

		/*
		 * This theme styles the visual editor to resemble the theme style,
		 * specifically font, colors, icons, and column width.
		 */
		add_editor_style( array( 'css/editor-style.css', vw_restaurant_lite_font_url() ) );

		// Theme Activation Notice
		global $pagenow;

		if (is_admin() && ('themes.php' == $pagenow) && isset( $_GET['activated'] )) {
			add_action('admin_notices', 'diner_restaurant_activation_notice');
		}

	}
	endif;

	add_action( 'after_setup_theme', 'diner_restaurant_setup' );

	// Notice after Theme Activation
	function diner_restaurant_activation_notice() {
		echo '<div class="notice notice-success is-dismissible welcome-notice">';
			echo '<div class="notice-row">';
				echo '<div class="notice-text">';
					echo '<p class="welcome-text1">'. esc_html__( '🎉 Welcome to VW Themes,', 'diner-restaurant' ) .'</p>';
					echo '<p class="welcome-text2">'. esc_html__( 'You are now using the Diner Restaurant theme, a beautifully designed theme to kickstart your website.', 'diner-restaurant' ) .'</p>';
					echo '<p class="welcome-text3">'. esc_html__( 'To help you get started quickly, use the options below:', 'diner-restaurant' ) .'</p>';
					echo '<span class="import-btn"><a href="'. esc_url( admin_url( 'themes.php?page=diner_restaurant_guide' ) ) .'" class="button button-primary">'. esc_html__( 'IMPORT DEMO', 'diner-restaurant' ) .'</a></span>';
					echo '<span class="demo-btn"><a href="'. esc_url( 'https://www.vwthemes.net/vw-diner-restaurant/' ) .'" class="button button-primary" target=_blank>'. esc_html__( 'VIEW DEMO', 'diner-restaurant' ) .'</a></span>';
					echo '<span class="upgrade-btn"><a href="'. esc_url( 'https://www.vwthemes.com/products/diner-restaurant-wordpress-theme' ) .'" class="button button-primary" target=_blank>'. esc_html__( 'UPGRADE TO PRO', 'diner-restaurant' ) .'</a></span>';
					echo '<span class="bundle-btn"><a href="'. esc_url( 'https://www.vwthemes.com/products/wp-theme-bundle' ) .'" class="button button-primary" target=_blank>'. esc_html__( 'BUNDLE OF 350+ THEMES', 'diner-restaurant' ) .'</a></span>';
				echo '</div>';
				echo '<div class="notice-img1">';
					echo '<img src="' . esc_url( get_template_directory_uri() . '/inc/getting-started/images/arrow-notice.png' ) . '" width="180" alt="' . esc_attr__( 'Diner Restaurant theme', 'diner-restaurant' ) . '" />';
				echo '</div>';
				echo '<div class="notice-img2">';
					echo '<img src="' . esc_url( get_template_directory_uri() . '/inc/getting-started/images/bundle-notice.png' ) . '" width="180" alt="' . esc_attr__( 'Diner Restaurant theme', 'diner-restaurant' ) . '" />';
				echo '</div>';	
			echo '</div>';	
		echo '</div>';
	}


	add_action( 'wp_enqueue_scripts', 'diner_restaurant_enqueue_styles' );
	function diner_restaurant_enqueue_styles() {
    	$parent_style = 'vw-restaurant-lite-basic-style'; // Style handle of parent theme.
    	
		wp_enqueue_style( 'bootstrap-style', get_template_directory_uri().'/css/bootstrap.css' );
		wp_enqueue_style( $parent_style, get_template_directory_uri() . '/style.css' );
		wp_enqueue_style( 'diner-restaurant-style', get_stylesheet_uri(), array( $parent_style ) );
		require get_theme_file_path( '/inline-style.php' );
		wp_add_inline_style( 'diner-restaurant-style',$vw_restaurant_lite_custom_css );
		require get_parent_theme_file_path( '/inline-style.php' );
		wp_add_inline_style( 'vw-restaurant-lite-basic-style',$vw_restaurant_lite_custom_css );
		wp_enqueue_style( 'diner-restaurant-block-style', get_theme_file_uri('/assets/css/blocks.css') );
		wp_enqueue_script( 'diner-restaurant-custom-scripts-jquery', get_theme_file_uri('/assets/js/custom.js') );
		wp_enqueue_style( 'diner-restaurant-block-patterns-style-frontend', get_theme_file_uri('/inc/block-patterns/css/block-frontend.css') );

		if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) {
			wp_enqueue_script( 'comment-reply' );
		}
	}
		
	add_action( 'init', 'diner_restaurant_remove_parent_function');
	function diner_restaurant_remove_parent_function() {
		remove_action( 'admin_notices', 'vw_restaurant_lite_activation_notice' );
		remove_action( 'admin_menu', 'vw_restaurant_lite_gettingstarted' );
	}

	add_action( 'customize_register', 'diner_restaurant_customize_register', 11 );
	function diner_restaurant_customize_register($wp_customize) {
		global $wp_customize;
		$wp_customize->remove_section( 'vw_restaurant_lite_upgrade_pro_link' );
		$wp_customize->remove_section( 'vw_restaurant_lite_get_started_link' );
		$wp_customize->remove_control( 'vw_restaurant_lite_topbar_hide_show' );
		$wp_customize->remove_control( 'vw_restaurant_lite_topbar_padding_top_bottom' );
		$wp_customize->remove_control( 'vw_restaurant_lite_cont_phone_icon' );
		$wp_customize->remove_control( 'vw_restaurant_lite_contact' );
		$wp_customize->remove_control( 'vw_restaurant_lite_cont_email_icon' );
		$wp_customize->remove_control( 'vw_restaurant_lite_email' );
		$wp_customize->remove_control( 'vw_restaurant_lite_resp_topbar_hide_show' );
		$wp_customize->remove_control( 'vw_restaurant_lite_sticky_header' );
		$wp_customize->remove_control( 'vw_restaurant_lite_sticky_header_padding' );
		$wp_customize->remove_control( 'vw_restaurant_lite_stickyheader_hide_show' );
		$wp_customize->remove_control( 'vw_restaurant_lite_social_icon_padding' );
		$wp_customize->remove_control( 'vw_restaurant_lite_social_icon_width' );
		$wp_customize->remove_control( 'vw_restaurant_lite_social_icon_height' );
		$wp_customize->remove_control( 'vw_restaurant_lite_social_icon_border_radius' );
		$wp_customize->remove_control( 'vw_restaurant_lite_slider_content_option' );
		$wp_customize->remove_control( 'vw_restaurant_lite_slider_content_padding_top_bottom' );
		$wp_customize->remove_control( 'vw_restaurant_lite_slider_content_padding_left_right' );
		$wp_customize->remove_section( 'vw_restaurant_lite_social_links' );

		//Social Media
		$wp_customize->add_setting( 'diner_restaurant_social_media',array(
	    	'default' => 0,
	      	'transport' => 'refresh',
	      	'sanitize_callback' => 'vw_restaurant_lite_switch_sanitization'
	    ));  
	    $wp_customize->add_control( new VW_Restaurant_Lite_Toggle_Switch_Custom_Control( $wp_customize, 'diner_restaurant_social_media',array(
	      	'label' => esc_html__( 'Show / Hide Social Media','diner-restaurant' ),
	      	'section' => 'vw_restaurant_lite_social_icon_settings'
	    )));

	    //Header
		$wp_customize->add_setting('diner_restaurant_header_book_btn_text',array(
			'default'=> '',
			'sanitize_callback'	=> 'sanitize_text_field'
		));
		$wp_customize->add_control('diner_restaurant_header_book_btn_text',array(
			'label'	=> esc_html__('Add Button Text','diner-restaurant'),
			'input_attrs' => array(
	            'placeholder' => esc_html__( 'BOOK TABLE', 'diner-restaurant' ),
	        ),
			'section'=> 'vw_restaurant_lite_topbar_icon',
			'type'=> 'text'
		));

		$wp_customize->add_setting('diner_restaurant_header_book_btn_link',array(
			'default'=> '',
			'sanitize_callback'	=> 'esc_url_raw'
		));
		$wp_customize->add_control('diner_restaurant_header_book_btn_link',array(
			'label'	=> esc_html__('Add Button Link','diner-restaurant'),
			'input_attrs' => array(
	            'placeholder' => esc_html__( 'www.example-info.com', 'diner-restaurant' ),
	        ),
			'section'=> 'vw_restaurant_lite_topbar_icon',
			'type'=> 'url'
		));

		$wp_customize->add_setting( 'diner_restaurant_slider_small_title', array(
        'default'           => '',
        'sanitize_callback' => 'sanitize_text_field'
	    ) );
	    $wp_customize->add_control( 'diner_restaurant_slider_small_title', array(
	        'label'    => __( 'Add Slider Small Text', 'diner-restaurant' ),
	        'input_attrs' => array(
	            'placeholder' => __( 'TASTY AND CRUNCHY', 'diner-restaurant' ),
	        ),
	        'section'  => 'vw_restaurant_lite_slidersettings',
	        'type'     => 'text'
	    ) );

		//Contact Box
		$wp_customize->add_setting('diner_restaurant_phone_icon',array(
		    'default' => 'fa fa-phone',
		    'sanitize_callback' => 'sanitize_text_field'
		)); 
		$wp_customize->add_control(new VW_Restaurant_Lite_Fontawesome_Icon_Chooser($wp_customize,'diner_restaurant_phone_icon',array(
		    'label' => __('Add Phone Number Icon','diner-restaurant'),
		    'transport' => 'refresh',
		    'section' => 'vw_restaurant_lite_topbar_icon',
		    'setting' => 'diner_restaurant_phone_icon',
		    'type'    => 'icon'
		)));

		$wp_customize->add_setting('diner_restaurant_phone_text',array(
			'default'=> '',
			'sanitize_callback'	=> 'sanitize_text_field'
		));
		$wp_customize->add_control('diner_restaurant_phone_text',array(
			'label'	=> __('Add Phone Text','diner-restaurant'),
			'input_attrs' => array(
	            'placeholder' => __( 'Call Us', 'diner-restaurant' ),
	        ),
			'section'=> 'vw_restaurant_lite_topbar_icon',
			'type'=> 'text'
		));

		$wp_customize->add_setting('diner_restaurant_phone_number',array(
			'default'	=> '',
			'sanitize_callback'	=> 'vw_restaurant_lite_sanitize_phone_number'
		));
		
		$wp_customize->add_control('diner_restaurant_phone_number',array(
			'label'	=> __('Add Phone Number','diner-restaurant'),
			'input_attrs' => array(
	            'placeholder' => __( '12345678', 'diner-restaurant' ),
	        ),
			'section'	=> 'vw_restaurant_lite_topbar_icon',
			'setting'	=> 'diner_restaurant_phone_number',
			'type'		=> 'text'
		));

		$wp_customize->add_setting('diner_restaurant_email_icon',array(
		    'default' => 'fa fa-envelope',
		    'sanitize_callback' => 'sanitize_text_field'
		)); 
		$wp_customize->add_control(new VW_Restaurant_Lite_Fontawesome_Icon_Chooser($wp_customize,'diner_restaurant_email_icon',array(
		    'label' => __('Add Email Icon','diner-restaurant'),
		    'transport' => 'refresh',
		    'section' => 'vw_restaurant_lite_topbar_icon',
		    'setting' => 'diner_restaurant_email_icon',
		    'type'    => 'icon'
		)));

		$wp_customize->add_setting('diner_restaurant_email_text',array(
			'default'=> '',
			'sanitize_callback'	=> 'sanitize_text_field'
		));
		$wp_customize->add_control('diner_restaurant_email_text',array(
			'label'	=> __('Add Email Text','diner-restaurant'),
			'input_attrs' => array(
	            'placeholder' => __( 'E-mail', 'diner-restaurant' ),
	        ),
			'section'=> 'vw_restaurant_lite_topbar_icon',
			'type'=> 'text'
		));

		$wp_customize->add_setting('diner_restaurant_email_address',array(
			'default'	=> '',
			'sanitize_callback'	=> 'sanitize_email'
		));
		
		$wp_customize->add_control('diner_restaurant_email_address',array(
			'label'	=> __('Add Email Address','diner-restaurant'),
			'input_attrs' => array(
	            'placeholder' => __( 'support@gmail.com', 'diner-restaurant' ),
	        ),
			'section'	=> 'vw_restaurant_lite_topbar_icon',
			'setting'	=> 'diner_restaurant_email_address',
			'type'		=> 'text'
		));

		$wp_customize->add_setting('diner_restaurant_location_icon',array(
		    'default' => 'fas fa-paper-plane',
		    'sanitize_callback' => 'sanitize_text_field'
		)); 
		$wp_customize->add_control(new VW_Restaurant_Lite_Fontawesome_Icon_Chooser($wp_customize,'diner_restaurant_location_icon',array(
		    'label' => __('Add Location Icon','diner-restaurant'),
		    'transport' => 'refresh',
		    'section' => 'vw_restaurant_lite_topbar_icon',
		    'setting' => 'diner_restaurant_location_icon',
		    'type'    => 'icon'
		)));

		$wp_customize->add_setting('diner_restaurant_location_text',array(
			'default'=> '',
			'sanitize_callback'	=> 'sanitize_text_field'
		));
		$wp_customize->add_control('diner_restaurant_location_text',array(
			'label'	=> __('Add Location Text','diner-restaurant'),
			'input_attrs' => array(
	            'placeholder' => __( 'Location', 'diner-restaurant' ),
	        ),
			'section'=> 'vw_restaurant_lite_topbar_icon',
			'type'=> 'text'
		));

		$wp_customize->add_setting('diner_restaurant_location',array(
			'default'=> '',
			'sanitize_callback'	=> 'sanitize_text_field'
		));
		$wp_customize->add_control('diner_restaurant_location',array(
			'label'	=> __('Add Location','diner-restaurant'),
			'input_attrs' => array(
	            'placeholder' => __( 'Your Location', 'diner-restaurant' ),
	        ),
			'section'=> 'vw_restaurant_lite_topbar_icon',
			'type'=> 'text'
		));

		//Popular Menu
		$wp_customize->add_section('diner_restaurant_popular_menu',array(
			'title'	=> __('Popular Menu','diner-restaurant'),
			'description' => __('Increase the number of tab and publish the settings and then refresh the page then the popular settings will increase.','diner-restaurant'),
			'panel' => 'vw_restaurant_lite_homepage_panel',
			'priority' => 10,
		));

		$wp_customize->add_setting('diner_restaurant_popular_menu_title',array(
			'default'=> '',
			'sanitize_callback'	=> 'sanitize_text_field'
		));	
		$wp_customize->add_control('diner_restaurant_popular_menu_title',array(
			'label'	=> esc_html__('Section Title','diner-restaurant'),
			'input_attrs' => array(
	            'placeholder' => esc_html__( 'Choose Popular Menu', 'diner-restaurant' ),
	        ),
			'section'=> 'diner_restaurant_popular_menu',
			'type'=> 'text'
		));

		$wp_customize->add_setting('diner_restaurant_popular_menu_tab_number',array(
			'default'=> '',
			'sanitize_callback'	=> 'sanitize_text_field'
		));	
		$wp_customize->add_control('diner_restaurant_popular_menu_tab_number',array(
			'description' => __('Publish and Refresh the page after select the number of tab.','diner-restaurant'),
			'label'	=> esc_html__('No of Tabs to show','diner-restaurant'),
			'section'=> 'diner_restaurant_popular_menu',
			'type'=> 'number'
		));	

		$featured_post = get_theme_mod('diner_restaurant_popular_menu_tab_number','');
	    for ( $j = 1; $j <= $featured_post; $j++ ) {
			$wp_customize->add_setting('diner_restaurant_services_text'.$j,array(
				'default'=> '',
				'sanitize_callback'	=> 'sanitize_text_field'
			));	
			$wp_customize->add_control('diner_restaurant_services_text'.$j,array(
				'label'	=> esc_html__('Tab ','diner-restaurant').$j,
				'input_attrs' => array(
		            'placeholder' => esc_html__( 'All', 'diner-restaurant' ),
		        ),
				'section'=> 'diner_restaurant_popular_menu',
				'type'=> 'text'
			));

			$args = array(
				'type'         => 'product',
				'child_of'     => 0,
				'parent'       => '',
				'orderby'      => 'term_group',
				'order'        => 'ASC',
				'hide_empty'   => false,
				'hierarchical' => 1,
				'number'       => '',
				'taxonomy'     => 'product_cat',
				'pad_counts'   => false
			);
		 	$categories = get_categories( $args );
			$cat_posts = array();
			$i = 0;
			$cat_posts[]='Select';
			foreach($categories as $category){
				if($i==0){
					$default = $category->slug;
					$i++;
				}
				$cat_posts[$category->slug] = $category->name;
			}

			$wp_customize->add_setting('diner_restaurant_popular_menu_category'.$j,array(
				'default'	=> 'select',
				'sanitize_callback' => 'vw_restaurant_lite_sanitize_choices',
			));
			$wp_customize->add_control('diner_restaurant_popular_menu_category'.$j,array(
				'type'    => 'select',
				'choices' => $cat_posts,
				'label' => __('Select Product Category to display Popular Menu','diner-restaurant'),
				'section' => 'diner_restaurant_popular_menu',
			));
		}
	}

	

	/**
	 * Enqueue block editor style
	 */
	function diner_restaurant_block_editor_styles() {
	    wp_enqueue_style( 'diner-restaurant-block-patterns-style-editor', get_theme_file_uri( '/inc/block-patterns/css/block-editor.css' ), false, '1.0', 'all' );
	}
	add_action( 'enqueue_block_editor_assets', 'diner_restaurant_block_editor_styles' );

	function diner_restaurant_sanitize_choices( $input, $setting ) {
	    global $wp_customize; 
	    $control = $wp_customize->get_control( $setting->id ); 
	    if ( array_key_exists( $input, $control->choices ) ) {
	        return $input;
	    } else {
	        return $setting->default;
	    }
	}

	function diner_restaurant_sanitize_dropdown_pages( $page_id, $setting ) {
	  	$page_id = absint( $page_id );
	  	return ( 'publish' == get_post_status( $page_id ) ? $page_id : $setting->default );
	}

	/* Theme Widgets Setup */

	function diner_restaurant_widgets_init() {
		register_sidebar( array(
			'name'          => __( 'Footer Navigation 1', 'diner-restaurant' ),
			'description'   => __( 'Appears on footer 1', 'diner-restaurant' ),
			'id'            => 'footer-1',
			'before_widget' => '<aside id="%1$s" class="widget %2$s">',
			'after_widget'  => '</aside>',
			'before_title'  => '<h3 class="widget-title">',
			'after_title'   => '</h3>',
		) );

		register_sidebar( array(
			'name'          => __( 'Footer Navigation 2', 'diner-restaurant' ),
			'description'   => __( 'Appears on footer 2', 'diner-restaurant' ),
			'id'            => 'footer-2',
			'before_widget' => '<aside id="%1$s" class="widget %2$s">',
			'after_widget'  => '</aside>',
			'before_title'  => '<h3 class="widget-title">',
			'after_title'   => '</h3>',
		) );

		register_sidebar( array(
			'name'          => __( 'Footer Navigation 3', 'diner-restaurant' ),
			'description'   => __( 'Appears on footer 3', 'diner-restaurant' ),
			'id'            => 'footer-3',
			'before_widget' => '<aside id="%1$s" class="widget %2$s">',
			'after_widget'  => '</aside>',
			'before_title'  => '<h3 class="widget-title">',
			'after_title'   => '</h3>',
		) );

		register_sidebar( array(
			'name'          => __( 'Footer Navigation 4', 'diner-restaurant' ),
			'description'   => __( 'Appears on footer 4', 'diner-restaurant' ),
			'id'            => 'footer-4',
			'before_widget' => '<aside id="%1$s" class="widget %2$s">',
			'after_widget'  => '</aside>',
			'before_title'  => '<h3 class="widget-title">',
			'after_title'   => '</h3>',
		) );
	}
	add_action( 'widgets_init', 'diner_restaurant_widgets_init' );

// Customizer Pro
load_template( ABSPATH . WPINC . '/class-wp-customize-section.php' );

class Diner_Restaurant_Customize_Section_Pro extends WP_Customize_Section {
	public $type = 'diner-restaurant';
	public $pro_text = '';
	public $pro_url = '';
	public function json() {
		$json = parent::json();
		$json['pro_text'] = $this->pro_text;
		$json['pro_url']  = esc_url( $this->pro_url );
		return $json;
	}
	protected function render_template() { ?>
		<li id="accordion-section-{{ data.id }}" class="accordion-section control-section control-section-{{ data.type }} cannot-expand">
			<h3 class="accordion-section-title">
				{{ data.title }}
				<# if ( data.pro_text && data.pro_url ) { #>
					<a href="{{ data.pro_url }}" class="button button-secondary alignright" target="_blank">{{ data.pro_text }}</a>
				<# } #>
			</h3>
		</li>
	<?php }
}

final class Diner_Restaurant_Customize {
	public static function get_instance() {
		static $instance = null;
		if ( is_null( $instance ) ) {
			$instance = new self;
			$instance->setup_actions();
		}
		return $instance;
	}
	private function __construct() {}
	private function setup_actions() {
		// Register panels, sections, settings, controls, and partials.
		add_action( 'customize_register', array( $this, 'sections' ) );
		// Register scripts and styles for the controls.
		add_action( 'customize_controls_enqueue_scripts', array( $this, 'enqueue_control_scripts' ), 0 );
	}
	public function sections( $manager ) {
		// Register custom section types.
		$manager->register_section_type( 'Diner_Restaurant_Customize_Section_Pro' );
		// Register sections.
		$manager->add_section( new Diner_Restaurant_Customize_Section_Pro( $manager, 'diner_restaurant_upgrade_pro_link',
		array(
			'priority'   => 1,
			'title'    => esc_html__( 'Diner Restaurant Pro', 'diner-restaurant' ),
			'pro_text' => esc_html__( 'UPGRADE PRO', 'diner-restaurant' ),
			'pro_url'  => esc_url('https://www.vwthemes.com/products/diner-restaurant-wordpress-theme'),
		)));

		// Register sections.
		$manager->add_section(new Diner_Restaurant_Customize_Section_Pro($manager,'diner_restaurant_get_started_link',array(
			'priority'   => 1,
			'title'    => esc_html__( 'DOCUMENTATION', 'diner-restaurant' ),
			'pro_text' => esc_html__( 'DOCS', 'diner-restaurant' ),
			'pro_url'  => esc_url('https://preview.vwthemesdemo.com/docs/free-diner-restaurant/'),
		)));
	}
	public function enqueue_control_scripts() {
		wp_enqueue_script( 'diner-restaurant-customize-controls', get_stylesheet_directory_uri() . '/assets/js/customize-controls-child.js', array( 'customize-controls' ) );
		wp_enqueue_style( 'diner-restaurant-customize-controls', get_stylesheet_directory_uri() . '/assets/css/customize-controls-child.css' );
	}
}
Diner_Restaurant_Customize::get_instance();

function diner_restaurant_init_setup() {
	/* Plugin Activation */
	require get_theme_file_path() . '/inc/getstart/plugin-activation.php';

	/* getstart */
	require get_theme_file_path('/inc/getstart/getstart.php');

	/* Block Pattern */
	require get_theme_file_path('/inc/block-patterns/block-patterns.php');

	/* TGM */
	require get_theme_file_path('/inc/tgm/tgm.php');

	define('DINER_RESTAURANT_FREE_THEME_DOC',__('https://preview.vwthemesdemo.com/docs/free-diner-restaurant/','diner-restaurant'));
	define('DINER_RESTAURANT_SUPPORT',__('https://wordpress.org/support/theme/diner-restaurant/','diner-restaurant'));
	define('DINER_RESTAURANT_REVIEW',__('https://wordpress.org/support/theme/diner-restaurant/reviews/','diner-restaurant'));
	define('DINER_RESTAURANT_BUY_NOW',__('https://www.vwthemes.com/products/diner-restaurant-wordpress-theme','diner-restaurant'));
	define('DINER_RESTAURANT_LIVE_DEMO',__('https://www.vwthemes.net/vw-diner-restaurant/','diner-restaurant'));
	define('DINER_RESTAURANT_PRO_DOC',__('https://preview.vwthemesdemo.com/docs/vw-diner-restaurant-pro/','diner-restaurant'));
	define('DINER_RESTAURANT_FAQ',__('https://www.vwthemes.com/faqs/','diner-restaurant'));
	define('DINER_RESTAURANT_CONTACT',__('https://www.vwthemes.com/contact/','diner-restaurant'));
	define('DINER_RESTAURANT_CHILD_THEME',__('https://developer.wordpress.org/themes/advanced-topics/child-themes/','diner-restaurant'));
	define('DINER_RESTAURANT_CREDIT',__('https://www.vwthemes.com/products/free-restaurant-wordpress-theme','diner-restaurant'));

	if ( ! function_exists( 'diner_restaurant_credit' ) ) {
		function diner_restaurant_credit(){
			echo "<a href=".esc_url(DINER_RESTAURANT_CREDIT)." target='_blank'>". esc_html__('Restaurant WordPress Theme','diner-restaurant') ."</a>";
		}
	}

	if ( ! defined( 'VW_RESTAURANT_LITE_GO_PRO' ) ) {
		define( 'VW_RESTAURANT_LITE_GO_PRO', 'https://www.vwthemes.com/products/diner-restaurant-wordpress-theme');
	}

	if ( ! defined( 'VW_RESTAURANT_LITE_GETSTARTED_URL' ) ) {
		define( 'VW_RESTAURANT_LITE_GETSTARTED_URL', 'themes.php?page=diner_restaurant_guide');
	}

}
add_action( 'after_setup_theme', 'diner_restaurant_init_setup' );