<?php
/* -------------------------------------------
 *  Charsoogh Functions
 *  Design by Tik4.com
 * -------------------------------------------*/
$charsoogh_theme_src = "zhaket";
if (version_compare(phpversion(), '7.2', '<')) {
  echo '<div style="direction: rtl; text-align: center">';
  echo '<b>'. __('Please upgrade your PHP version to version 7.2' , 'charsoogh') .'</b> <br />';
  echo '<a href="https://tik4.com/?p=2478" target="_blank">'. __('Tutorial on changing the PHP version in Cpanel' , 'charsoogh') .'</a><br />';
  echo '<a href="https://tik4.com/?p=2482" target="_blank">'. __('Tutorial on changing the PHP version in the DirectAdmin' , 'charsoogh') .'</a>';
  echo '</div>';
  exit();
}
include_once( 'includes/charsoogh.php' );
add_theme_support('post-thumbnails');
if (function_exists('add_image_size')){
add_image_size( 'img-350-260', 350, 260, true);
add_image_size( 'img-260-200', 260, 200, true);
add_image_size( 'img-150-150', 150, 150, true);
}
function register_my_menu() { register_nav_menus(array('main-menu' => __( 'Main Menu' , 'charsoogh' ),'top-bar-menu' => __( 'Top Bar Menu' , 'charsoogh' ),'footer-menu' => __( 'Footer Menu' , 'charsoogh' ),));}
function wp_nav_menu_no_ul() { $options = array( 'echo' => false, 'container' => false, 'theme_location' => 'top-bar-menu', 'fallback_cb'=> 'fall_back_menu' ); $menu = wp_nav_menu($options); echo preg_replace(array( '#^<ul [^>]*>#', '#</ul>$#' ), '', $menu); } function fall_back_menu(){ return; }
