Пример #1
0
 private function Ep_GetSidebars()
 {
     $sidebars = array('no-sidebar' => '', 'main-sidebar' => __('Default Sidebar', 'epicomedia'), 'page-sidebar' => __('Default Page Sidebar', 'epicomedia'));
     if (ep_opt('custom_sidebars') != '') {
         $arr = explode(',', ep_opt('custom_sidebars'));
         foreach ($arr as $bar) {
             $sidebars[$bar] = str_replace('%666', ',', $bar);
         }
     }
     return $sidebars;
 }
Пример #2
0
        }
        ?>
            <div class="wrapGoogleMap sectionOverlay <?php 
        echo esc_attr($homeOverlayTexture);
        ?>
">
                <div id="homeGoogleMap">
                </div>
            </div>
        <?php 
    } else {
        if (ep_opt('home-type-switch') == 'home-revolutionSlider') {
            ?>
            <!-- Revolution Slider -->
            <span id='hideMenuFirst'></span>
            <div id="homeHeight" class="revolutionSlider">
                <?php 
            $homeRevolutionslider = '[rev_slider ' . ep_opt('home-rev-slide') . ']';
            echo do_shortcode($homeRevolutionslider);
            ?>
            </div>

        <?php 
        }
    }
}
?>

    </div>
</section>
<div id="startHere"></div>
Пример #3
0
    ?>
            
                            <!-- Footer logo  -->
                            <div class="footerlogo">
                                <img class="secoundLogo" src=" <?php 
    ep_eopt('footer-logo');
    ?>
" alt="footer_Logo">
                            </div>
                
                        <?php 
}
?>
                        
                        <?php 
if (ep_opt('footer-copyright')) {
    ?>
                        
                             <!-- Footer CopyRight   -->
                            <div class="copyright">
                                 <?php 
    ep_eopt('footer-copyright');
    ?>
                            </div>
                            
                        <?php 
}
?>
                                                  
                    </div>
                </div>
Пример #4
0
function ep_theme_fonts()
{
    $fontBody = ep_opt('font-body');
    $fontHeading = ep_opt('font-headings');
    $fontNav = ep_opt('font-navigation');
    $ShortcodeFont = ep_opt('font-shortcode');
    $fontTextRotator = '';
    $slides = get_posts(array('post_type' => 'slider', 'numberposts' => -1, 'tax_query' => array(array('taxonomy' => 'slider_cats', 'field' => 'slug', 'terms' => ep_opt('home-slider-cat')))));
    foreach ($slides as $slideID) {
        $caption_style = get_post_meta($slideID->ID, 'caption-style', true);
        if ($caption_style == 'style5') {
            $fontTextRotator = 'Arvo';
        }
    }
    //Fix for setup problem (shouldn't happen after the update, just for old setups)
    if ('' == $fontBody && '' == $fontHeading && '' == $fontNav && '' == $ShortcodeFont) {
        $fontBody = $fontHeading = $fontNav = $ShortcodeFont = '';
    }
    if ($fontTextRotator != '') {
        $fonts = array($fontBody, $fontHeading, $fontNav, $ShortcodeFont, $fontTextRotator);
        $fontVariants = array(array(300, 400, 500, 600, 700), array(300, 400, 500, 600), array(400), array(300, 400, 500, 600), array(400));
        //Suggested variants if available
    } else {
        $fonts = array($fontBody, $fontHeading, $fontNav, $ShortcodeFont);
        $fontVariants = array(array(300, 400, 500, 600, 700), array(300, 400, 500, 600), array(400), array(300, 400, 500, 600));
        //Suggested variants if available
    }
    $fonts = array_filter($fonts);
    //remove empty elements
    $fontList = array();
    $fontReq = 'http://fonts.googleapis.com/css?family=';
    $gf = new ep_GoogleFonts(ep_path_combine(THEME_LIB, 'googlefonts.json'));
    //Build font list
    foreach ($fonts as $key => $font) {
        $duplicate = false;
        //Search for duplicate
        foreach ($fontList as $item) {
            if ($font == $item['font']) {
                $duplicate = true;
                $item['variants'] = array_unique(array_merge($item['variants'], $fontVariants[$key]));
                break;
            }
        }
        //Add
        if (!$duplicate) {
            $fontList[] = array('font' => $font, 'variants' => $fontVariants[$key]);
        }
    }
    $temp = array();
    foreach ($fontList as $item) {
        $font = $gf->GetFontByName($item['font']);
        if (null == $font) {
            continue;
        }
        $variants = array();
        foreach ($item['variants'] as $variant) {
            //Check if font object has the variant
            if (in_array($variant, $font->variants)) {
                $variants[] = $variant;
            } else {
                if (400 == $variant && in_array('regular', $font->variants)) {
                    $variants[] = $variant;
                }
            }
        }
        $query = preg_replace('/ /', '+', $item['font']);
        if (count($variants)) {
            $query .= ':' . implode(',', $variants);
        }
        $temp[] = $query;
    }
    if (count($temp)) {
        $fontReq .= implode('|', $temp);
        wp_enqueue_style('ep_fonts', $fontReq);
    }
}
Пример #5
0
                    
                    <?php 
    if (ep_opt('notification_title')) {
        ?>
                         <!-- notification bar - title  -->
                         <div class="notificationTitle">
                            <?php 
        ep_eopt('notification_title');
        ?>
                         </div>
                    <?php 
    }
    ?>
                    
                    <?php 
    if (ep_opt('notification_text')) {
        ?>
                         <!-- notification bar - text  -->
                         <div class="notificationText">
                            <?php 
        ep_eopt('notification_text');
        ?>
                         </div>
                    <?php 
    }
    ?>

                </div>

                <!-- notification bar - buttons  -->
                <div class="notificationBtns">
Пример #6
0
    ?>
}
<?php 
}
$socialcolor2 = ep_opt('social_custom2_color');
if (ep_opt('social_custom2_color')) {
    ?>
.socialLinkShortcode.custom2 a:before{
	background: <?php 
    echo esc_attr($socialcolor2);
    ?>
}
<?php 
}
$socialLogo1 = ep_opt('social_custom1_image');
$socialLogo2 = ep_opt('social_custom2_image');
?>
span.icon.icon-custom1{
    background-image: url("<?php 
echo esc_url($socialLogo1);
?>
");
}
span.icon.icon-custom2{
    background-image: url("<?php 
echo esc_url($socialLogo2);
?>
");
}

/*######## Style Overrides ########*/
Пример #7
0
    }
    foreach ($attachment_ids as $attachment_id) {
        $image = wp_get_attachment_image_src($attachment_id, apply_filters('single_product_large_thumbnail_size', 'shop_single'));
        if ($zoom == 1) {
            $big_image = wp_get_attachment_image_src($attachment_id, 'full');
            echo '<div class="swiper-slide easyzoom" style="background-image:url(' . $image[0] . ')" data-zoom-image="' . $big_image[0] . '"></div>';
        } else {
            echo '<div class="swiper-slide" style="background-image:url(' . $image[0] . ')"></div>';
        }
    }
    ?>
				</div>
	    	</div>
	    	<?php 
} else {
    $zoom = ep_opt('shop-enable-zoom');
    // detect side bar position that set in admin panel
    if (has_post_thumbnail()) {
        $image = wp_get_attachment_image_src(get_post_thumbnail_id($post->ID), apply_filters('single_product_large_thumbnail_size', 'shop_single'));
        if ($zoom == 1) {
            $big_image = wp_get_attachment_image_src(get_post_thumbnail_id($post->ID), 'full');
            echo '<div class="swiper-slide easyzoom" style="background-image:url(' . $image[0] . ')" data-zoom-image="' . $big_image[0] . '"></div>';
        } else {
            echo '<div class="swiper-slide" style="background-image:url(' . $image[0] . ')" ></div>';
        }
    }
    foreach ($attachment_ids as $attachment_id) {
        $image = wp_get_attachment_image_src($attachment_id, apply_filters('single_product_large_thumbnail_size', 'shop_single'));
        if ($zoom == 1) {
            $big_image = wp_get_attachment_image_src($attachment_id, 'full');
            echo '<div class="swiper-slide easyzoom" style="background-image:url(' . $image[0] . ')" data-zoom-image="' . $big_image[0] . '"></div>';
Пример #8
0
                        } else {
                            get_template_part('templates/single');
                        }
                    }
                }
            }
        }
    }
    // end of the loop.
}
// end if
?>
                </div>

                <?php 
if (ep_opt('blog-sidebar-position') == 1) {
    ?>
                    <!-- Right Sidebar  -->
                    <div class="span3">
                        <?php 
    ep_get_sidebar('main-sidebar');
    ?>
                    </div>
                <?php 
}
?>
            </div>
        </div>
    </div>
</div>
<?php 
Пример #9
0
function ep_login_logo()
{
    $login_logo = ep_opt('login-logo') ? ep_opt('login-logo') : THEME_ADMIN_URI . '/img/wp_login_logo.png';
    echo '<style type="text/css"> h1 a { background: url(' . $login_logo . ') center no-repeat !important; width:302px !important; height:67px !important; } </style>';
}
Пример #10
0
                <?php 
    if (ep_opt('footer_title') || ep_opt('footer_subtitle')) {
        ?>

                    <div class="titleSpace">
                        <?php 
        if (ep_opt('footer_title')) {
            ?>
                            <div class="title"><h3><?php 
            ep_eopt('footer_title');
            ?>
</h3></div>
                        <?php 
        }
        if (ep_opt('footer_subtitle')) {
            ?>
                            <div class="subtitle"><?php 
            ep_eopt('footer_subtitle');
            ?>
</div>
                        <?php 
        }
        ?>
                    </div>

                <?php 
    }
    ?>

            </div>
Пример #11
0
    while ($main_query->have_posts()) {
        $main_query->the_post();
        global $post;
        $post_name = $post->post_name;
        $post_id = get_the_ID();
        $separate_page = get_post_meta($post_id, "page-position-switch", true);
        if ($separate_page !== "0" && $post_id != $current_page_id) {
            // custom section
            if (get_post_meta($post_id, "page-type-switch", true) == "custom-section") {
                get_template_part('templates/section', 'custom');
            } else {
                if (get_post_meta($post_id, "page-type-switch", true) == "blog-section" && $blogCount == 0) {
                    get_template_part('templates/section', 'blog');
                    $blogCount++;
                }
            }
        }
    }
}
wp_reset_query();
// Footer Map
if (ep_opt('footer-enable-map')) {
    get_template_part('templates/section', 'location');
}
// Footer Widget bar
get_template_part('templates/section', 'widgetized_footer');
?>
    </div>
</div>
<?php 
get_footer();
Пример #12
0
                if (is_active_sidebar('woocommerce_wishlist')) {
                    echo " has_wishlist";
                }
                ?>
"></span>
                 <?php 
            }
            ?>

            </div>  
        </div>    
        
        <!-- Footer Social Link  -->
        <div class="vertical_menu_social">
            <?php 
            $social_icons_style = ep_opt('social-icon-style') == 1 ? 'light' : 'dark';
            ?>
            <ul class="social-icons <?php 
            echo esc_attr($social_icons_style);
            ?>
">
                                
                <?php 
            ep_socialIcon('social_facebook_url', __('Facebook Profile', 'epicomedia'), 'icon-facebook3', 'facebook');
            //Facebook
            ep_socialIcon('social_twitter_url', __('Twitter Profile', 'epicomedia'), 'icon-twitter2', 'twitter');
            // Twitter
            ep_socialIcon('social_vimeo_url', __('Vimeo Profile', 'epicomedia'), 'icon-vimeo', 'vimeo');
            // Vimeo
            ep_socialIcon('social_youtube_url', __('YouTube Profile', 'epicomedia'), 'icon-youtube', 'youtube');
            // Youtube
Пример #13
0
$footerWidgets = ep_opt('footer_widgets');
if ($footerWidgets == 2 || $footerWidgets == 3 || $footerWidgets == 4) {
    $footerWidgets = 2;
} else {
    if ($footerWidgets == 5) {
        $footerWidgets = 3;
    }
}
//Main sidebar
register_sidebar(array_merge($defaults, array('id' => 'main-sidebar')));
//Page sidebar
register_sidebar(array_merge($defaults, array('name' => __('Page Sidebar', 'epicomedia'), 'id' => 'page-sidebar')));
//Footer widgets
for ($i = 0; $i < $footerWidgets; $i++) {
    register_sidebar(array_merge($defaults, array('name' => __('Footer Widget ' . ($i + 1), 'epicomedia'), 'id' => 'footer-widget-' . ($i + 1))));
}
//Woocommerce Sidebar
register_sidebar(array_merge($defaults, array('name' => __('Woocommerce Sidebar', 'epicomedia'), 'id' => 'woocommerce-sidebar')));
// WooCommerce Drop Down Cart
register_sidebar(array_merge($defaults, array('name' => __('Woocommerce Drop Down cart', 'epicomedia'), 'id' => 'woocommerce_dropdown_cart', 'description' => esc_html__('This widget area should be used only for WooCommerce dropdown cart widget', 'epicomedia'))));
// WooCommerce Wishlist
register_sidebar(array_merge($defaults, array('name' => __('Woocommerce wishlist', 'epicomedia'), 'id' => 'woocommerce_wishlist', 'description' => esc_html__('This widget area should be used only for WooCommerce Wishlist', 'epicomedia'))));
//Custom Sidebars
if (ep_opt('custom_sidebars') != '') {
    $sidebars = explode(',', ep_opt('custom_sidebars'));
    $i = 0;
    foreach ($sidebars as $bar) {
        register_sidebar(array_merge($defaults, array('id' => "custom-{$i}", 'name' => str_replace('%666', ',', $bar))));
        $i++;
    }
}
Пример #14
0
<?php

get_header();
// menu
get_template_part('templates/section', 'nav');
get_template_part('templates/shop-head');
?>

<!-- main-content wrap pass to djax -->
<div class="main-content" id="main-content">
    
<?php 
//Get the sidebar option
$sidebarPos = ep_opt('shop-sidebar-position');
if (get_post()) {
    // Get Page Post Id
    $post_id = get_the_ID();
}
$shopid = get_option('woocommerce_shop_page_id');
?>

    <!-- Page Content-->
    <div class="wrap woocommercepage" id="pageHeight">

        <?php 
if (0 == $sidebarPos) {
    ?>
    
            <?php 
    if (is_product()) {
        ?>
Пример #15
0
 public function Ep_GetValue($key)
 {
     return ep_opt($key);
 }