Beispiel #1
0
function compare_sidebar_params()
{
    $home_sidebars = compare_get_option('home_sidebars');
    if (empty($home_sidebars)) {
        $home_sidebars = 2;
    }
    $sidebars = array();
    for ($i = 1; $i <= $home_sidebars; $i++) {
        $sidebars[__('Home Sidebar ', 'compare') . $i] = 'home-sidebar-' . $i;
    }
    return array(array("type" => "dropdown", "value" => $sidebars, "holder" => "div", "class" => "", "heading" => __("Home Sidebar", "compare"), "param_name" => "home_sidebar", "description" => __("Select Sidebar To Show", "compare")));
}
Beispiel #2
0
 public function __construct($data)
 {
     $this->mode = compare_get_option('paypal_mode');
     $this->url = "https://api-3t" . $this->mode . ".paypal.com/nvp";
     $this->version = urlencode('109.0');
     if (!empty($data['username']) && !empty($data['password']) && !empty($data['signature'])) {
         $this->username = urlencode($data['username']);
         $this->password = urlencode($data['password']);
         $this->signature = urlencode($data['signature']);
         $this->returnUrl = $data['returnUrl'];
         $this->cancelUrl = $data['cancelUrl'];
     } else {
         echo '<div class="alert alert-danger">API username, API password, APi signature and Cancel URL can not be blank.</div>';
     }
 }
Beispiel #3
0
$secondary_color = compare_get_option('secondary_color');
$secondary_font_color = compare_get_option('secondary_font_color');
$secondary_color_hvr = compare_get_option('secondary_color_hvr');
$secondary_font_color_hvr = compare_get_option('secondary_font_color_hvr');
$top_bar_bg_color = compare_get_option('top_bar_bg_color');
$top_bar_font_color = compare_get_option('top_bar_font_color');
$submenu_bg_color = compare_get_option('submenu_bg_color');
$submenu_font_color = compare_get_option('submenu_font_color');
$submenu_bottom_border_color = compare_get_option('submenu_bottom_border_color');
$categories_font_color_hvr = compare_get_option('categories_font_color_hvr');
$categories_bg_color_hvr = compare_get_option('categories_bg_color_hvr');
$copyrights_bg_color = compare_get_option('copyrights_bg_color');
$copyrights_font_color = compare_get_option('copyrights_font_color');
$copyrights_link_color = compare_get_option('copyrights_link_color');
$font_family = compare_get_option('font_family');
$site_logo_padding = compare_get_option('site_logo_padding');
?>


.top-bar{
    background-color: <?php 
echo $top_bar_bg_color;
?>
;
}
/* top bar font color - - - */
.top-bar .navbar ul li,
.top-bar .navbar ul li a,
.top-bar .navbar ul li a i,
.top-bar .navbar ul li a:hover,
.top-bar .navbar ul li a:focus,
Beispiel #4
0
            <div class="white-title clearfix">
				<div class="white-block-border clearfix">
					 <div class="pull-left">
						<?php 
echo compare_get_white_title_icon();
?>
						<h3><?php 
_e('404 Error Page', 'compare');
?>
</h3>
					</div>
				</div>
            </div>  		
			<div class="error-image">
				<?php 
$error_img = compare_get_option('error_img');
if (!empty($error_img['url'])) {
    echo '<img src="' . esc_url($error_img['url']) . '" width="' . esc_attr($error_img['width']) . '" height="' . esc_attr($error_img['height']) . '" alt="404">';
}
?>
			</div>
			<p><?php 
_e('Sorry but this post or page does not exists!', 'compare');
?>
</p>				
		</div>
		<?php 
echo do_shortcode('[products tabs="latest" products="10" rows="1"][/products]');
?>
	</div>
</section>
    $hash = $_GET['hash'];
    global $wpdb;
    $store = $wpdb->get_results($wpdb->prepare("SELECT * FROM {$wpdb->prefix}stores WHERE store_update = %s", $hash));
    $store = array_shift($store);
    if (!empty($store)) {
        ?>
                                <form class="register-store">
                                    <div class="row">
                                        <div class="col-md-12">
                                            <div class="input-group">
                                                <label for="store_package"><?php 
        esc_attr_e('Chose your package', 'compare');
        ?>
 <span class="required">*</span>
                                                <?php 
        $all_packages_link = compare_get_option('all_packages_link');
        if (!empty($all_packages_link)) {
            ?>
                                                <a href="<?php 
            echo esc_url($all_packages_link);
            ?>
" class="pull-right"> <?php 
            _e('Check list of available packages', 'compare');
            ?>
</a></label>
                                                <?php 
        }
        ?>
                                                <select name="store_package" id="store_package" class="form-control">
                                                    <option value=""><?php 
        _e('Select Package', 'compare');
Beispiel #6
0
<?php

$show_breadcrumbs = compare_get_option('show_breadcrumbs');
$breadcrumbs = compare_get_breadcrumbs();
if (!empty($breadcrumbs)) {
    ?>
	<section class="breadcrumb-section <?php 
    echo $show_breadcrumbs == 'yes' ? '' : esc_attr('breadcrumb-hide');
    ?>
">
		<div class="container">
			<?php 
    echo $breadcrumbs;
    ?>
		</div>
	</section>
<?php 
} else {
    ?>
	<section class="breadcrumb-section">
	</section>
<?php 
}
Beispiel #7
0
?>
                            </li>
                        </ul>
                    </div>
                </div>
                <div class="products-box">
                    <div class="search-overlay row">  
                        <i class="fa fa-spin fa-spinner"></i>
                        <p><?php 
_e('Loading results...', 'compare');
?>
</p>
                    </div>
                    <div class="row">                
                    <?php 
$product_box_style = compare_get_option('product_box_style');
if (!empty($product_view)) {
    $product_box_style = $product_view;
}
if ($products->have_posts()) {
    while ($products->have_posts()) {
        $products->the_post();
        if ($counter == 3) {
            echo '</div><div class="row">';
            $counter = 0;
        }
        $counter++;
        echo '<div class="col-sm-' . ($product_box_style == 'grid' ? esc_attr('4') : esc_attr('12')) . '">';
        if ($product_box_style == 'grid') {
            include get_template_directory() . '/includes/product-box.php';
        } else {
Beispiel #8
0
if (!empty($content)) {
    ?>
                <div class="white-block-content">
                    <div class="page-content clearfix">
                        <?php 
    echo apply_filters('the_content', $content);
    ?>
                    </div>
                </div>
            <?php 
}
?>
        </div> 
        <div class="row">
        <?php 
$packages = trim(compare_get_option('packages'));
$counter = 0;
if (!empty($packages)) {
    $packages = explode("\n", $packages);
    foreach ($packages as $package) {
        $temp = explode("|", $package);
        $link = add_query_arg(array('package' => $temp[1] . '-' . $temp[2]), compare_get_permalink_by_tpl('page-tpl_register_store'));
        if ($counter == 2) {
            echo '</div><div class="row">';
            $counter = 0;
        }
        $counter++;
        ?>
                    <div class="col-md-6">
                        <div class="white-block <?php 
        echo !empty($temp[3]) == 'A' ? esc_attr('active') : '';
Beispiel #9
0
<?php

/**********************************************************************
	***********************************************************************
	PROPERSHOP COMMENTS
	**********************************************************************/
if (!empty($_SERVER['SCRIPT_FILENAME']) && 'comments.php' == basename($_SERVER['SCRIPT_FILENAME'])) {
    die('Please do not load this page directly. Thanks!');
}
if (post_password_required()) {
    return;
}
$products_single = compare_get_option('products_single');
if (isset($_GET['variation'])) {
    $products_single = 'style' . $_GET['variation'];
}
global $compare_can_review;
$compare_can_review = 'can_review';
if (comments_open()) {
    ?>


    <!-- row -->
    <div class="comments">
    	<?php 
    if (have_comments()) {
        ?>
    		<?php 
        if ($products_single !== 'style1' && is_singular('product') || !is_singular('product')) {
            ?>
	    	<div class="white-block">
Beispiel #10
0
	Template Name: Contact Page
*/
get_header();
the_post();
?>
<section>
    <div class="container">
        <div class="white-block map-container">
            <div class="contact_map">
                <?php 
$contact_map = compare_get_option('contact_map');
if (!empty($contact_map[0])) {
    foreach ($contact_map as $long_lat) {
        echo '<input type="hidden" value="' . esc_attr($long_lat) . '" class="contact_map_marker">';
    }
    $contact_map_scroll_zoom = compare_get_option('contact_map_scroll_zoom');
    if ($contact_map_scroll_zoom == 'yes') {
        echo '<input type="hidden" value="1" class="contact_map_scroll_zoom">';
    }
    ?>
                    <div id="map" class="embed-responsive-item"></div>
                    <?php 
}
?>
            </div>
        </div>

        <div class="row">
            <div class="col-md-<?php 
echo is_active_sidebar('sidebar-contact') ? '9' : '12';
?>
Beispiel #11
0
<?php

get_sidebar('footer');
?>

<?php 
$footer_copyrights = compare_get_option('footer_copyrights');
$footer_copyrights_image = compare_get_option('footer_copyrights_image');
if (!empty($footer_copyrights) || !empty($footer_copyrights_image['url'])) {
    ?>
	<footer class="footer">
		<div class="container">
			<div class="row">
				<div class="col-md-12">
					<?php 
    $show_to_top = compare_get_option('show_to_top');
    if ($show_to_top == 'yes') {
        ?>
						<div class="to-top">
							<a href="javascript:;">
								<i class="fa fa-angle-double-up"></i>
							</a>
						</div>
					<?php 
    }
    ?>

					<div class="pull-left">
						<?php 
    echo wp_kses_post($footer_copyrights);
    ?>
Beispiel #12
0
						<?php 
    include get_template_directory() . '/includes/views/reviews.php';
    ?>
						<?php 
    include get_template_directory() . '/includes/views/tags.php';
    ?>
						<?php 
    include get_template_directory() . '/includes/views/categories.php';
    ?>
					<?php 
}
?>
				</div>

				<?php 
$similar_num = compare_get_option('similar_num');
if (!empty($similar_num)) {
    $product_cats = get_the_terms(get_the_ID(), 'product-cat');
    $product_cats_list = array();
    if (!empty($product_cats)) {
        foreach ($product_cats as $product_cat) {
            $product_cats_list[] = $product_cat->slug;
        }
    }
    $args = array('post_type' => 'product', 'posts_per_page' => $similar_num, 'post__not_in' => array(get_the_ID()), 'post_status' => 'publish', 'tax_query' => array('taxonomy' => 'product-cat', 'field' => 'slug', 'terms' => $product_cats_list));
    $similar = new WP_Query($args);
    $product_ids = wp_list_pluck($similar->posts, 'ID');
    $product_metas = compare_product_item_meta($product_ids);
    if ($similar->have_posts()) {
        ?>
					<div class="owl-parent">
Beispiel #13
0
function compare_get_compare_slugs()
{
    global $compare_slugs;
    foreach ($compare_slugs as &$slug) {
        $trans = compare_get_option('trans_' . str_replace('-', '_', $slug));
        if (!empty($trans)) {
            $slug = $trans;
        }
    }
}
Beispiel #14
0
    if ($has_nav) {
        wp_nav_menu(array('theme_location' => 'top-navigation', 'menu_class' => 'nav navbar-nav clearfix', 'container' => false, 'echo' => true, 'items_wrap' => '<ul class="%2$s">%3$s' . (class_exists('ReduxFramework') ? '<li class="register-nav"><a href="' . esc_url(compare_get_permalink_by_tpl('page-tpl_register_store')) . '"><i class="fa fa-unlock-alt"></i>' . __('REGISTER YOUR STORE', 'compare') . '</a></li>' : '') . '</ul>', 'depth' => 10, 'walker' => new compare_walker()));
    }
    ?>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </header>
<?php 
}
?>

<?php 
$enable_search_bar = compare_get_option('enable_search_bar');
if ($enable_search_bar == 'yes') {
    ?>
    <header class="search_bar">
        <div class="container">
            <a href="javascript:;" class="toggle-categories">
                <i class="fa fa-list-ul"></i>
            </a>        
            <div class="dropdown <?php 
    echo is_front_page() ? 'always-open' : '';
    ?>
">
                <button class="btn btn-default dropdown-toggle" type="button" id="dropdownMenu1" data-toggle="dropdown" aria-haspopup="true" aria-expanded="true">
                    <i class="fa fa-bars"></i>
                    <?php 
    _e('Categories', 'compare');
Beispiel #15
0
    /**
     * @see Walker::start_el()
     * @since 3.0.0
     *
     * @param string $output Passed by reference. Used to append additional content.
     * @param object $item Menu item data object.
     * @param int $depth Depth of menu item. Used for padding.
     * @param object $args
     */
    function start_el(&$output, $item, $depth = 0, $args = array(), $id = 0)
    {
        global $_wp_nav_menu_max_depth;
        $_wp_nav_menu_max_depth = $depth > $_wp_nav_menu_max_depth ? $depth : $_wp_nav_menu_max_depth;
        $indent = $depth ? str_repeat("\t", $depth) : '';
        ob_start();
        $item_id = esc_attr($item->ID);
        $removed_args = array('action', 'customlink-tab', 'edit-menu-item', 'menu-item', 'page-tab', '_wpnonce');
        $original_title = '';
        if ('taxonomy' == $item->type) {
            $original_title = get_term_field('name', $item->object_id, $item->object, 'raw');
            if (is_wp_error($original_title)) {
                $original_title = false;
            }
        } elseif ('post_type' == $item->type) {
            $original_object = get_post($item->object_id);
            $original_title = $original_object->post_title;
        }
        $classes = array('menu-item menu-item-depth-' . $depth, 'menu-item-' . esc_attr($item->object), 'menu-item-edit-' . (isset($_GET['edit-menu-item']) && $item_id == $_GET['edit-menu-item'] ? 'active' : 'inactive'));
        $title = $item->title;
        if (!empty($item->_invalid)) {
            $classes[] = 'menu-item-invalid';
            /* translators: %s: title of menu item which is invalid */
            $title = sprintf(__('%s (Invalid)', 'compare'), $item->title);
        } elseif (isset($item->post_status) && 'draft' == $item->post_status) {
            $classes[] = 'pending';
            /* translators: %s: title of menu item in draft status */
            $title = sprintf(__('%s (Pending)', 'compare'), $item->title);
        }
        $title = empty($item->label) ? $title : $item->label;
        ?>
    <li id="menu-item-<?php 
        echo esc_attr($item_id);
        ?>
" class="<?php 
        echo implode(' ', $classes);
        ?>
">
        <dl class="menu-item-bar">
            <dt class="menu-item-handle">
                <span class="item-title"><?php 
        echo esc_html($title);
        ?>
</span>
                <span class="item-controls">
                    <span class="item-type"><?php 
        echo esc_html($item->type_label);
        ?>
</span>
                    <span class="item-order hide-if-js">
                        <a href="<?php 
        echo wp_nonce_url(esc_url(add_query_arg(array('action' => 'move-up-menu-item', 'menu-item' => $item_id), esc_url(remove_query_arg($removed_args, admin_url('nav-menus.php'))))), 'move-menu_item');
        ?>
" class="item-move-up"><abbr title="<?php 
        esc_attr_e('Move up', 'compare');
        ?>
">&#8593;</abbr></a>
                        |
                        <a href="<?php 
        echo wp_nonce_url(esc_url(add_query_arg(array('action' => 'move-down-menu-item', 'menu-item' => $item_id), esc_url(remove_query_arg($removed_args, admin_url('nav-menus.php'))))), 'move-menu_item');
        ?>
" class="item-move-down"><abbr title="<?php 
        esc_attr_e('Move down', 'compare');
        ?>
">&#8595;</abbr></a>
                    </span>
                    <a class="item-edit" id="edit-<?php 
        echo esc_attr($item_id);
        ?>
" title="<?php 
        esc_attr_e('Edit Menu Item', 'compare');
        ?>
" href="<?php 
        echo isset($_GET['edit-menu-item']) && $item_id == $_GET['edit-menu-item'] ? admin_url('nav-menus.php') : esc_url(add_query_arg('edit-menu-item', $item_id, esc_url(remove_query_arg($removed_args, admin_url('nav-menus.php#menu-item-settings-' . $item_id)))));
        ?>
"><?php 
        _e('Edit Menu Item', 'compare');
        ?>
</a>
                </span>
            </dt>
        </dl>

        <div class="menu-item-settings" id="menu-item-settings-<?php 
        echo esc_attr($item_id);
        ?>
">
            <?php 
        if ('custom' == $item->type) {
            ?>
                <p class="field-url description description-wide">
                    <label for="edit-menu-item-url-<?php 
            echo esc_attr($item_id);
            ?>
">
                        <?php 
            _e('URL', 'compare');
            ?>
<br />
                        <input type="text" id="edit-menu-item-url-<?php 
            echo esc_attr($item_id);
            ?>
" class="widefat code edit-menu-item-url" name="menu-item-url[<?php 
            echo esc_attr($item_id);
            ?>
]" value="<?php 
            echo esc_attr($item->url);
            ?>
" />
                    </label>
                </p>
            <?php 
        }
        ?>
            <p class="description description-thin">
                <label for="edit-menu-item-title-<?php 
        echo esc_attr($item_id);
        ?>
">
                    <?php 
        _e('Navigation Label', 'compare');
        ?>
<br />
                    <input type="text" id="edit-menu-item-title-<?php 
        echo esc_attr($item_id);
        ?>
" class="widefat edit-menu-item-title" name="menu-item-title[<?php 
        echo esc_attr($item_id);
        ?>
]" value="<?php 
        echo esc_attr($item->title);
        ?>
" />
                </label>
            </p>
            <p class="description description-thin">
                <label for="edit-menu-item-attr-title-<?php 
        echo esc_attr($item_id);
        ?>
">
                    <?php 
        _e('Title Attribute', 'compare');
        ?>
<br />
                    <input type="text" id="edit-menu-item-attr-title-<?php 
        echo esc_attr($item_id);
        ?>
" class="widefat edit-menu-item-attr-title" name="menu-item-attr-title[<?php 
        echo esc_attr($item_id);
        ?>
]" value="<?php 
        echo esc_attr($item->post_excerpt);
        ?>
" />
                </label>
            </p>
            <p class="field-link-target description">
                <label for="edit-menu-item-target-<?php 
        echo esc_attr($item_id);
        ?>
">
                    <input type="checkbox" id="edit-menu-item-target-<?php 
        echo esc_attr($item_id);
        ?>
" value="_blank" name="menu-item-target[<?php 
        echo esc_attr($item_id);
        ?>
]"<?php 
        checked($item->target, '_blank');
        ?>
 />
                    <?php 
        _e('Open link in a new window/tab', 'compare');
        ?>
                </label>
            </p>
            <p class="field-css-classes description description-thin">
                <label for="edit-menu-item-classes-<?php 
        echo esc_attr($item_id);
        ?>
">
                    <?php 
        _e('CSS Classes (optional)', 'compare');
        ?>
<br />
                    <input type="text" id="edit-menu-item-classes-<?php 
        echo esc_attr($item_id);
        ?>
" class="widefat code edit-menu-item-classes" name="menu-item-classes[<?php 
        echo esc_attr($item_id);
        ?>
]" value="<?php 
        echo esc_attr(implode(' ', $item->classes));
        ?>
" />
                </label>
            </p>
            <p class="field-xfn description description-thin">
                <label for="edit-menu-item-xfn-<?php 
        echo esc_attr($item_id);
        ?>
">
                    <?php 
        _e('Link Relationship (XFN)', 'compare');
        ?>
<br />
                    <input type="text" id="edit-menu-item-xfn-<?php 
        echo esc_attr($item_id);
        ?>
" class="widefat code edit-menu-item-xfn" name="menu-item-xfn[<?php 
        echo esc_attr($item_id);
        ?>
]" value="<?php 
        echo esc_attr($item->xfn);
        ?>
" />
                </label>
            </p>
            <p class="field-description description description-wide">
                <label for="edit-menu-item-description-<?php 
        echo esc_attr($item_id);
        ?>
">
                    <?php 
        _e('Description', 'compare');
        ?>
<br />
                    <textarea id="edit-menu-item-description-<?php 
        echo esc_attr($item_id);
        ?>
" class="widefat edit-menu-item-description" rows="3" cols="20" name="menu-item-description[<?php 
        echo esc_attr($item_id);
        ?>
]"><?php 
        echo esc_html($item->description);
        // textarea_escaped
        ?>
</textarea>
                    <span class="description"><?php 
        _e('The description will be displayed in the menu if the current theme supports it.', 'compare');
        ?>
</span>
                </label>
            </p>        
            <?php 
        /*
         * This is the added field
         */
        ?>
      
            <p class="field-custom description description-wide">
                <label for="edit-menu-item-custom-<?php 
        echo esc_attr($item_id);
        ?>
">
                    <?php 
        _e('Assign Mega Menu', 'compare');
        ?>
<br />
                    <select class="widefat" name="mega-menu-set[<?php 
        echo esc_attr($item_id);
        ?>
]" id="edit-menu-item-custom-<?php 
        echo esc_attr($item_id);
        ?>
">
                        <option value=""><?php 
        _e('No Mega Menu', 'compare');
        ?>
</option>
                        <?php 
        $mega_menu_sidebars = compare_get_option('mega_menu_sidebars');
        if (empty($mega_menu_sidebars)) {
            $mega_menu_sidebars = 5;
        }
        for ($i = 1; $i <= $mega_menu_sidebars; $i++) {
            $mega_menu_sidebars_array['mega-menu-' . $i] = __('Mega Menu Sidebar ', 'compare') . $i;
        }
        foreach ($mega_menu_sidebars_array as $id => $name) {
            echo '<option value="' . $id . '" ' . ($item->mega_menu_custom == $id ? 'selected="selected"' : '') . '>' . $name . '</option>';
        }
        ?>
                    </select>                
                </label>
            </p>
            <?php 
        /*
         * end added field
         */
        ?>
            <div class="menu-item-actions description-wide submitbox">
                <?php 
        if ('custom' != $item->type && $original_title !== false) {
            ?>
                    <p class="link-to-original">
                        <?php 
            printf(__('Original: %s', 'compare'), '<a href="' . esc_attr($item->url) . '">' . esc_html($original_title) . '</a>');
            ?>
                    </p>
                <?php 
        }
        ?>
                <a class="item-delete submitdelete deletion" id="delete-<?php 
        echo esc_attr($item_id);
        ?>
" href="<?php 
        echo wp_nonce_url(add_query_arg(array('action' => 'delete-menu-item', 'menu-item' => $item_id), esc_url(remove_query_arg($removed_args, admin_url('nav-menus.php')))), 'delete-menu_item_' . $item_id);
        ?>
"><?php 
        _e('Remove', 'compare');
        ?>
</a> <span class="meta-sep"> | </span> <a class="item-cancel submitcancel" id="cancel-<?php 
        echo esc_attr($item_id);
        ?>
" href="<?php 
        echo esc_url(add_query_arg(array('edit-menu-item' => $item_id, 'cancel' => time()), esc_url(remove_query_arg($removed_args, admin_url('nav-menus.php')))));
        ?>
#menu-item-settings-<?php 
        echo esc_attr($item_id);
        ?>
"><?php 
        _e('Cancel', 'compare');
        ?>
</a>
            </div>

            <input class="menu-item-data-db-id" type="hidden" name="menu-item-db-id[<?php 
        echo esc_attr($item_id);
        ?>
]" value="<?php 
        echo esc_attr($item_id);
        ?>
" />
            <input class="menu-item-data-object-id" type="hidden" name="menu-item-object-id[<?php 
        echo esc_attr($item_id);
        ?>
]" value="<?php 
        echo esc_attr($item->object_id);
        ?>
" />
            <input class="menu-item-data-object" type="hidden" name="menu-item-object[<?php 
        echo esc_attr($item_id);
        ?>
]" value="<?php 
        echo esc_attr($item->object);
        ?>
" />
            <input class="menu-item-data-parent-id" type="hidden" name="menu-item-parent-id[<?php 
        echo esc_attr($item_id);
        ?>
]" value="<?php 
        echo esc_attr($item->menu_item_parent);
        ?>
" />
            <input class="menu-item-data-position" type="hidden" name="menu-item-position[<?php 
        echo esc_attr($item_id);
        ?>
]" value="<?php 
        echo esc_attr($item->menu_order);
        ?>
" />
            <input class="menu-item-data-type" type="hidden" name="menu-item-type[<?php 
        echo esc_attr($item_id);
        ?>
]" value="<?php 
        echo esc_attr($item->type);
        ?>
" />
        </div><!-- .menu-item-settings-->
        <ul class="menu-item-transport"></ul>
    <?php 
        $output .= ob_get_clean();
    }
Beispiel #16
0
function compare_inform_store($message, $mail, $subject)
{
    $headers = array();
    $headers[] = "MIME-Version: 1.0";
    $headers[] = "Content-Type: text/html; charset=UTF-8";
    $email_sender = compare_get_option('email_sender');
    $name_sender = compare_get_option('name_sender');
    if (!empty($email_sender) && !empty($name_sender)) {
        $headers[] = "From: " . $from_name . " <" . $from_mail . ">";
    }
    $info = @wp_mail($mail, $subject, $message, $headers);
}