public static function custom_export() { $config['theme_options'] = theme_options(); $config['widgets'] = Base_Export::getWidgetsConf(); Base_Export::printfAttachmentUrlMapping(); printf('%s' . Base_Export::OPEN_TAG . '%s' . Base_Export::CLOSE_TAG, "\t", base64_encode(serialize($config))); }
function register_event_custom_post_type() { $arg = array('labels' => array('name' => __('Events', 'theme_admin'), 'singular_name' => __('Event', 'theme_admin'), 'add_new' => __('Add New', 'theme_admin'), 'add_new_item' => __('Add New Event', 'theme_admin'), 'edit_item' => __('Edit Event', 'theme_admin'), 'new_item' => __('New Event', 'theme_admin'), 'view_item' => __('View Event', 'theme_admin'), 'search_items' => __('Search Event', 'theme_admin'), 'not_found' => __('No Event found', 'theme_admin'), 'not_found_in_trash' => __('No Event found in Trash', 'theme_admin'), 'parent_item_colon' => ''), 'singular_label' => __('Event', 'theme_admin'), 'public' => true, 'exclude_from_search' => false, 'show_ui' => true, 'capability_type' => 'post', 'hierarchical' => false, 'rewrite' => array('with_front' => false, 'slug' => '/' . theme_options('event', 'slug', 'event')), 'query_var' => 'event', '_builtin' => false, 'supports' => array('title', 'editor', 'thumbnail'), 'taxonomies' => array(), 'show_in_menu' => true, 'has_archive' => false); // Custom Icon if (is_readable(THEME_TYPES_DIR . '/event/icon.png')) { $arg['menu_icon'] = THEME_TYPES_URI . '/event/icon.png'; } register_post_type('event', $arg); //register taxonomy for Platform register_taxonomy('event_category', 'event', array('hierarchical' => false, 'labels' => array('name' => __('Category', 'theme_admin'), 'singular_name' => __('Category', 'theme_admin'), 'search_items' => __('Search Category', 'theme_admin'), 'popular_items' => __('Popular Category', 'theme_admin'), 'all_items' => __('All Category', 'theme_admin'), 'parent_item' => null, 'parent_item_colon' => null, 'edit_item' => __('Edit Category', 'theme_admin'), 'update_item' => __('Update Category', 'theme_admin'), 'add_new_item' => __('Add New Category', 'theme_admin'), 'new_item_name' => __('New Category Name', 'theme_admin'), 'separate_items_with_commas' => __('Separate Category with commas', 'theme_admin'), 'add_or_remove_items' => __('Add or remove Category', 'theme_admin'), 'choose_from_most_used' => __('Choose from the most used Category', 'theme_admin'), 'menu_name' => __('Category', 'theme_admin')), 'public' => true, 'show_in_nav_menus' => true, 'show_ui' => true, 'show_admin_column' => true, 'sort' => true, 'show_tagcloud' => false, 'query_var' => 'cateogry')); }
function custom_login_logo() { $custom_login_logo = theme_options('branding', 'branding_admin_logo'); if ($custom_login_logo != '') { $img = wp_get_attachment_image_src($custom_login_logo, 'full'); if ($img[1] > 320) { echo '<style type="text/css">#login { width: ' . $img[1] . 'px; }</style>'; } echo '<style type="text/css">#login h1{ margin-bottom: 10px; margin-left: 8px; } #login h1 a { background-image:url(' . wp_get_attachment_url($custom_login_logo) . ') !important; background-position: center center; background-size: auto; height: ' . $img[2] . 'px; width: 100%;</style>'; } }
function widget($args, $instance) { extract($args); $title = apply_filters('widget_title', empty($instance['title']) ? __('Recent Tweets', 'theme_front') : $instance['title'], $instance, $this->id_base); $username = $instance['username']; $count = $instance['count']; echo $before_widget; if ($title) { echo $before_title . $title . $after_title; } ?> <div class="twitter-box"> <?php if (theme_options('advance', 'twitter_consumer_key') && theme_options('advance', 'twitter_consumer_secret') && theme_options('advance', 'twitter_user_token') && theme_options('advance', 'twitter_user_secret')) { ?> <span class="tweet" data-username="******" data-count="<?php echo $count; ?> " data-modpath="<?php echo admin_url('admin-ajax.php'); ?> "></span> <?php } else { ?> <p>Please set Twitter App info at "WP-Admin > Appearance > Theme Options > Advance > Twitter App"</p> <?php } ?> <a href="https://twitter.com/<?php echo $username; ?> " class="twitter-follow-button" data-show-count="false" data-lang="en" data-align="<?php echo theme_options('appearance', 'text_rtl') == 'on' ? 'right' : 'left'; ?> " data-width="200px">Follow @<?php echo $username; ?> </a> <script>!function(d,s,id){var js,fjs=d.getElementsByTagName(s)[0];if(!d.getElementById(id)){js=d.createElement(s);js.id=id;js.src="//platform.twitter.com/widgets.js";fjs.parentNode.insertBefore(js,fjs);}}(document,"script","twitter-wjs");</script> </div> <?php echo $after_widget; }
public function __construct() { $this->lib = THEME_CUSTOM_LIBS_DIR . '/twitter/lib/'; $this->cache_dir = THEME_CUSTOM_LIBS_DIR . '/twitter/tw-cache/'; $this->consumer_key = theme_options('advance', 'twitter_consumer_key'); $this->consumer_secret = theme_options('advance', 'twitter_consumer_secret'); $this->user_token = theme_options('advance', 'twitter_user_token'); $this->user_secret = theme_options('advance', 'twitter_user_secret'); // Initialize paths and etc. $this->pathify($this->cache_dir); $this->pathify($this->lib); $this->message = ''; // Set server-side debug params if ($this->debug === true) { error_reporting(-1); } else { error_reporting(0); } }
function theme_footer() { if (theme_options('advance', 'show_customize') == 'on' && !isset($_REQUEST['disable_customize'])) { get_template_part('section', 'customize-panel'); } if (theme_options('advance', 'analytic_ua')) { ?> <script type="text/javascript"> var _gaq = _gaq || []; _gaq.push(['_setAccount', <?php echo theme_options('advance', 'analytic_ua'); ?> ]); _gaq.push(['_trackPageview']); (function() { var ga = document.createElement('script'); ga.type = 'text/javascript'; ga.async = true; ga.src = ('https:' == document.location.protocol ? 'https://ssl' : 'http://www') + '.google-analytics.com/ga.js'; var s = document.getElementsByTagName('script')[0]; s.parentNode.insertBefore(ga, s); })(); </script> <?php } }
<?php $config = array('title' => __('General Options', 'theme_admin'), 'group_id' => 'general', 'context' => 'normal', 'priority' => 'low', 'types' => array('page')); $options = array(array('type' => 'on_off', 'id' => 'show_main_title', 'toggle' => 'toggle-show-title', 'title' => __('Show Title', 'theme_admin'), 'default' => 'on', 'description' => __('turn off to hide title section', 'theme_admin')), array('type' => 'text', 'id' => 'custom_main_title', 'toggle_group' => 'toggle-show-title toggle-show-title-on', 'title' => __('Custom Title', 'theme_admin'), 'description' => __('this text will override the normal page/post title', 'theme_admin')), array('type' => 'text', 'id' => 'custom_sub_title', 'toggle_group' => 'toggle-show-title toggle-show-title-on', 'title' => __('Custom Sub Title', 'theme_admin'), 'description' => __('this text will be placed below Title', 'theme_admin')), array('type' => 'radio', 'id' => 'page_layout', 'toggle' => 'toggle-page-layout', 'title' => __('Page Layout', 'theme_admin'), 'description' => '', 'default' => theme_options('page', 'default_layout', 'full-width'), 'options' => array('full-width' => 'Full Width', 'sidebar' => 'Sidebar Right')), array('type' => 'select', 'id' => 'custom_sidebar', 'toggle_group' => 'toggle-page-layout toggle-page-layout-sidebar', 'title' => __('Custom Sidebar', 'theme_admin'), 'description' => __('leave blank to use default sidebar', 'theme_admin'), 'default' => '', 'source' => array('option-custom-sidebar' => ''), 'options' => array('' => 'choose ...'))); new metaboxes_tool($config, $options); $config = array('title' => __('General Options', 'theme_admin'), 'group_id' => 'general', 'context' => 'normal', 'priority' => 'low', 'types' => array('portfolio', 'event')); $options = array(array('type' => 'on_off', 'id' => 'show_main_title', 'toggle' => 'toggle-show-title', 'title' => __('Show Title', 'theme_admin'), 'default' => 'on', 'description' => __('turn off to hide title section', 'theme_admin')), array('type' => 'text', 'id' => 'custom_main_title', 'toggle_group' => 'toggle-show-title toggle-show-title-on', 'title' => __('Custom Title', 'theme_admin'), 'description' => __('this text will override the normal page/post title', 'theme_admin')), array('type' => 'text', 'id' => 'custom_sub_title', 'toggle_group' => 'toggle-show-title toggle-show-title-on', 'title' => __('Custom Sub Title', 'theme_admin'), 'description' => __('this text will be placed below Title', 'theme_admin'))); new metaboxes_tool($config, $options);
<?php get_header(); ?> <div id="content" class="post-content"> <div class="container"> <?php if (theme_options('page', '404_page')) { $stacks = get_post_meta(theme_options('page', '404_page'), '_stack_builder_stacks', true); if (is_array($stacks)) { foreach ($stacks as $stack) { $stack['id'] = 'stack-' . $post->ID . '-' . $stack['stack_id']; if ($stack['template_id'] == 'page_content') { $stack['template_id'] = 'page_content_full_width'; gen_stack($stack); } else { gen_stack($stack); } } } else { // In case no stack meta $stack = array('template_id' => 'page_content_full_width'); $stack['id'] = 'stack-' . $post->ID; gen_stack($stack); } } else { get_template_part('/stacks/stack', 'title'); } ?>
<?php get_footer('pre'); ?> <footer> <div class="container"> <div id="footer-right"> <nav id="footer-nav"> <?php wp_nav_menu(array('container' => '', 'menu_id' => 'footer-nav-list', 'menu_class' => false, 'theme_location' => 'footer', 'menu' => 'footer', 'depth' => 1, 'fallback_cb' => '')); ?> </nav> </div> <div id="footer-left"><?php echo stripslashes(theme_options('footer', 'footer_copyright_text')); ?> </div> </div> </footer> </div> <?php wp_footer(); ?> </body> </html>
</div><!-- .m-carousel --> <?php if (count($posts) > $slide_enable_bound) { ?> <div class="m-carousel-control slide-control top-right-slide-control"> <a href="#" class="m-carousel-prev"><i class="icon icon-angle-left"></i></a><a href="#" class="m-carousel-next"><i class="icon icon-angle-right"></i></a> </div> <?php } ?> </div><!-- .span12 --> <?php if ($slide_enable_bound == 3 && theme_options('appearance', 'text_rtl') == 'on') { ?> <div class="span3"> <div class="padding-left-20"> <?php if ($stack['stack_desc']) { ?> <?php echo apply_filters('the_content', $stack['stack_desc']); ?> <?php } ?> <?php if ($stack['button_text']) {
<div class="clear"></div> <!-- Author Box --> <?php if (is_single() && theme_options('blog', 'single_author_box') == 'on') { ?> <?php get_template_part('part', 'author-box'); ?> <?php } ?> <!-- Comment --> <?php if (comments_open() && !(is_page() && theme_options('page', 'comment_enable') == 'off')) { ?> <?php comments_template(); ?> <?php } ?> </div> </div> </div> <aside class="span4 sidebar"> <?php global $post; if (get_post_meta($post->ID, '_general_custom_sidebar', true)) {
$img_attr = wp_get_attachment_image_src($images_list[0], 'full'); ?> <div class="slides slide-with-pagination" data-effect="<?php echo theme_options('portfolio', 'img_slide_effect'); ?> " data-width="<?php echo $img_attr[1]; ?> " data-height="<?php echo $img_attr[2]; ?> " data-pagination="true" data-autoplay="true" data-interval="<?php echo theme_options('portfolio', 'img_slide_pause') * 1000; ?> " data-speed="<?php echo theme_options('portfolio', 'img_slide_animate_speed') * 1000; ?> "> <?php foreach ($images_list as $image_id) { ?> <div class="slide"> <?php echo gen_responsive_image_block($image_id, array(array('width' => 290, 'media' => '(max-width: 767px)'), array('width' => 290 * 2, 'media' => '(max-width: 767px) and (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi)'), array('width' => 466, 'media' => '(min-width: 768px)'), array('width' => 466 * 2, 'media' => '(min-width: 768px) and (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi)'), array('width' => 600, 'media' => '(min-width: 980px)'), array('width' => 600 * 2, 'media' => '(min-width: 980px) and (-webkit-min-device-pixel-ratio: 2), (min-resolution: 192dpi)'))); ?> </div> <?php } ?> </div><!-- .slides --> <?php
/** * main function. checks for authorization and renders the * required admin section. */ function admin_main($authorised) { echo "\n<div id=\"channel_admin\" class=\"frame\">"; if ($authorised) { admin_menu(); if (array_key_exists(CST_ADMIN_DOMAIN, $_REQUEST)) { switch ($_REQUEST[CST_ADMIN_DOMAIN]) { case CST_ADMIN_DOMAIN_FOLDER: $show = folder_admin(); break; case CST_ADMIN_DOMAIN_CHANNEL: $show = channel_admin(); break; case CST_ADMIN_DOMAIN_CONFIG: $show = config_admin(); break; case CST_ADMIN_DOMAIN_ITEM: $show = item_admin(); break; case CST_ADMIN_DOMAIN_PLUGINS: $show = plugins_admin(); break; case CST_ADMIN_DOMAIN_THEMES: $show = themes_admin(); break; case CST_ADMIN_DOMAIN_TAGS: $show = tags_admin(); break; case CST_ADMIN_DOMAIN_PLUGIN_OPTIONS: $show = plugin_options_admin(); break; case CST_ADMIN_DOMAIN_THEME_OPTIONS: $show = theme_options_admin(); break; default: break; } } if (array_key_exists(CST_ADMIN_VIEW, $_REQUEST) || isset($show)) { if (!isset($show)) { $show = $_REQUEST[CST_ADMIN_VIEW]; } switch ($show) { case CST_ADMIN_DOMAIN_CONFIG: config(); break; case CST_ADMIN_DOMAIN_CHANNEL: channels(); break; case CST_ADMIN_DOMAIN_FOLDER: folders(); break; case CST_ADMIN_DOMAIN_OPML: opml(); break; case CST_ADMIN_DOMAIN_NONE: break; case CST_ADMIN_DOMAIN_ITEM: items(); break; case CST_ADMIN_DOMAIN_SYSINFO: sysinfo(); break; case CST_ADMIN_DOMAIN_DASHBOARD: dashboard(); break; case CST_ADMIN_DOMAIN_PLUGINS: plugins(); break; case CST_ADMIN_DOMAIN_THEMES: themes(); break; case CST_ADMIN_DOMAIN_TAGS: tags(); break; case CST_ADMIN_DOMAIN_PLUGIN_OPTIONS: plugin_options(); break; case CST_ADMIN_DOMAIN_THEME_OPTIONS: theme_options(); break; default: } } else { if (true == getConfig('rss.config.defaultdashboard')) { dashboard(); } else { channels(); } } echo "\n<div class=\"clearer\"></div>\n"; } else { rss_error(sprintf(__('<h1>Not Authorized!</h1>You are not authorized to access the administration interface. Please follow <a href="%s">this link</a> back to the main page. Have a nice day!'), getPath()), RSS_ERROR_ERROR, true); } echo "</div>\n"; }
<?php if (theme_options('footer', 'pre_footer_show') != 'off') { ?> <section id="pre-footer"> <div class="container"> <div class="row"> <?php $pre_footer_layout = theme_options('footer', 'pre_footer_layout'); if ($pre_footer_layout == '3-colums') { ?> <?php } elseif ($pre_footer_layout == '1-column') { ?> <div class="span12"> <?php if (dynamic_sidebar('footer_1')) { } ?> </div> <?php } elseif ($pre_footer_layout == '2-columns') { ?> <div class="span6">
function show_page() { switch ($_GET['page']) { case 'homepage_settings': include_once dirname(__FILE__) . '/homepage_settings.php'; homepage_settings(); break; case 'manage_sidebars': include_once dirname(__FILE__) . '/manage_sidebars.php'; manage_sidebars(); break; case 'manage_users': include_once dirname(__FILE__) . '/manage_users.php'; manage_users(); break; case 'social_links': include_once dirname(__FILE__) . '/social_links.php'; social_links(); break; default: include_once dirname(__FILE__) . '/theme_options.php'; theme_options(); break; } }
"><i class="icon icon-envelope"></i></a></li><?php } ?> <?php if (theme_options('header', 'rss') == 'on') { ?> <li class="rss"><a href="<?php bloginfo('rss2_url'); ?> "><i class="icon icon-rss"></i></a></li><?php } ?> <?php if (theme_options('header', 'search') == 'on') { ?> <li class="search"> <a href="#"><i class="icon icon-search"></i></a> <form action="<?php echo home_url('/'); ?> "><input type="text" name="s" /></form> </li> <?php } ?> </ul> <?php
<div class="stack stack-twitter" id="<?php echo $stack['id']; ?> "> <div class="container"> <div class="twitter-box"> <div class="row"> <div class="span9"> <?php if (theme_options('advance', 'twitter_consumer_key') && theme_options('advance', 'twitter_consumer_secret') && theme_options('advance', 'twitter_user_token') && theme_options('advance', 'twitter_user_secret')) { ?> <span class="tweet" data-username="******" data-modpath="<?php echo admin_url('admin-ajax.php'); ?> "></span> <?php } else { ?> <ul class="tweet_list"><li>Please set Twitter App info at "WP-Admin > Appearance > Theme Options > Advance > Twitter App"</li></ul> <?php } ?> </div> <div class="span3"> <a href="https://twitter.com/<?php echo $stack['stack_title']; ?> " class="twitter-follow-button" data-show-count="false" data-lang="en" data-align="right" data-width="200px">Follow @<?php
function select($option) { $value = $this->value($option); $toggle = isset($option['toggle']) ? ' toggle="' . $this->toggle($option) . '"' : ''; // Source : Post Type if (isset($option['source']['post_type'])) { $source[''] = ''; $args = array('post_type' => $option['source']['post_type'], 'numberposts' => -1, 'orderby' => 'parent', 'order' => 'DESC', 'suppress_filters' => 0); $posts = get_posts($args); foreach ($posts as $post) { $source[$post->ID] = $post->post_title . ' (' . $post->ID . ')'; } } // Source : RevSlider if (isset($option['source']['revslider']) && class_exists('RevSlider')) { $slider = new RevSlider(); $revsliders = $slider->getArrSlidersShort(); foreach ($revsliders as $id => $name) { $source[$id] = $name . ' (' . $id . ')'; } } // Source : Layer Slider if (isset($option['source']['layer_slider'])) { global $wpdb; $table_name = $wpdb->prefix . "layerslider"; if ($wpdb->get_var("SHOW TABLES LIKE '{$table_name}'") == $table_name) { $sliders = $wpdb->get_results("SELECT * FROM {$table_name}\n\t\t\t\t\t\t\t\t\t\tWHERE flag_hidden = '0' AND flag_deleted = '0'\n\t\t\t\t\t\t\t\t\t\tORDER BY id ASC LIMIT 200"); if (!empty($sliders)) { foreach ($sliders as $slider) { $source[$slider->id] = $slider->name . ' (' . $slider->id . ')'; } } } } // Source : Category if (isset($option['source']['category'])) { $args = array('type' => $option['source']['category'], 'orderby' => 'term_group'); $taxanomies = get_categories($args); foreach ($taxanomies as $taxanomy) { $source[$taxanomy->term_id] = $taxanomy->category_nicename; } } // Source : Taxonomy if (isset($option['source']['taxonomy'])) { $args = array('taxonomy' => $option['source']['taxonomy'], 'orderby' => 'term_group'); $taxanomies = get_categories($args); foreach ($taxanomies as $taxanomy) { $source[$taxanomy->term_id] = $taxanomy->category_nicename; } } // Source : Font Awesome if (isset($option['source']['font-awesome'])) { $source[''] = 'Select icon ...'; asort($GLOBALS['font_awesome_list']); foreach ($GLOBALS['font_awesome_list'] as $key => $val) { $source[$key] = str_replace('icon-', '', $val); } } // Source : Option Custom Sidebar if (isset($option['source']['option-custom-sidebar'])) { if (is_array(theme_options('sidebar', 'custom_sidebars'))) { foreach (theme_options('sidebar', 'custom_sidebars') as $list) { $source[preg_replace('/[^A-Za-z0-9\\-]/', '', str_replace(' ', '-', strtolower($list['stack_title'])))] = $list['stack_title']; } } } // Source : Google Web Font if (isset($option['source']['gfonts'])) { $items = get_transient(THEME_SLUG . 'gfont_items'); if (!$items) { // No transient, request the new one $google_api_url = 'https://www.googleapis.com/webfonts/v1/webfonts?key=AIzaSyALn_gIORMu90pZJhO4-z5xULIWH9Lce-A'; $response = wp_remote_retrieve_body(wp_remote_get($google_api_url, array('sslverify' => false))); if (is_wp_error($response)) { // Failed, get from option $items = get_option(THEME_SLUG . 'gfont_items'); } else { // Success $response = json_decode($response); $items = $response->items; // Store set_transient(THEME_SLUG . 'gfont_items', $items, 60 * 60 * 12); if (!add_option(THEME_SLUG . 'gfont_items', $items)) { update_option(THEME_SLUG . 'gfont_items', $items); } } } // Add to source $source[''] = __('Please Select', 'theme_admin'); if ($items) { foreach ($items as $item) { $source[$item->family] = $item->family; } } else { $source[$value] = $value; } } // Multiple $multiple = isset($option['multiple']) ? ' multiple size="' . $option['multiple'] . '"' : ''; $name = isset($option['multiple']) ? 'name="' . $this->name($option) . '[]"' : 'name="' . $this->name($option) . '"'; // Generate echo '<select ' . $multiple . ' class="input-select" ' . $name . '" id="' . $this->id($option) . '" ' . $toggle . '>'; if (isset($option['options'])) { foreach ($option['options'] as $select_slug => $select_title) { $selected = $select_slug == $value || is_array($value) && in_array($select_slug, $value) ? 'selected="selected"' : ''; echo '<option value="' . $select_slug . '" ' . $selected . '>' . $select_title . '</option>'; } } if (isset($source)) { foreach ($source as $select_slug => $select_title) { $selected = $select_slug == $value || is_array($value) && in_array($select_slug, $value) ? 'selected="selected"' : ''; echo '<option value="' . $select_slug . '" ' . $selected . '>' . $select_title . '</option>'; } } echo '</select>'; }
<?php if (get_post_meta($post->ID, '_general_page_layout', true)) { get_template_part('layout', get_post_meta($post->ID, '_general_page_layout', true)); } else { get_template_part('layout', theme_options('page', 'default_layout', 'full-width')); }
<?php // 3rd Lib Style wp_enqueue_style('carousel', THEME_URI . '/css/carousel.css', true, THEME_VERSION); wp_enqueue_style('font-awesome', THEME_URI . '/css/font-awesome.min.css', true, THEME_VERSION); wp_enqueue_style('fancybox', THEME_URI . '/js/fancybox/jquery.fancybox-1.3.4.css', true, THEME_VERSION); // Theme Style wp_enqueue_style('layout', THEME_URI . '/css/layout.css', true, THEME_VERSION); wp_enqueue_style('screen', THEME_URI . '/css/screen.css', true, THEME_VERSION); // RTL if (theme_options('appearance', 'text_rtl') == 'on') { wp_enqueue_style('rtl', THEME_URI . '/css/rtl.css', true, THEME_VERSION); } // Responsive if (theme_options('appearance', 'enable_responsive') != 'off') { wp_enqueue_style('responsive', THEME_URI . '/css/media-queries.css', true, THEME_VERSION); } // Customize Box if (theme_options('advance', 'show_customize') == 'on') { wp_enqueue_style('customize-panel', THEME_URI . '/css/customize-panel.css', true, THEME_VERSION); } // Standard style.css for child-theme wp_enqueue_style('theme-style', get_stylesheet_uri(), false, THEME_VERSION); // Exclude CSS from Better WordPress Minify add_filter('bwp_minify_style_ignore', 'exclude_my_css'); function exclude_my_css($excluded) { $excluded = array('font-awesome'); return $excluded; }
echo get_permalink($portfolios_page_id); ?> "><i class="icon icon-th"></i> <?php echo get_the_title($portfolios_page_id); ?> </a></div> <?php } ?> <?php } elseif (is_singular('event')) { ?> <?php if (theme_options('event', 'archive')) { $event_page_id = get_wpml_object_id(theme_options('event', 'archive'), 'page'); ?> <div id="page-breadcrumb"><a href="<?php echo get_permalink($event_page_id); ?> "><i class="icon icon-th"></i> <?php echo get_the_title($event_page_id); ?> </a></div> <?php } ?> <?php } elseif (is_single()) { ?>
function theme_sidebars() { $custom_sidebars = theme_options('sidebar', 'custom_sidebars'); if ($custom_sidebars) { foreach ($custom_sidebars as $custom_sidebar) { $sidebar_name = $custom_sidebar['stack_title']; $sidebar_desc = __('Custom Sidebar Widget Area', 'theme_admin'); register_sidebar(array('id' => preg_replace('/[^A-Za-z0-9\\-]/', '', str_replace(' ', '-', strtolower($sidebar_name))), 'name' => $sidebar_name . ' (custom)', 'description' => $sidebar_desc, 'before_title' => '<div class="widget-title">', 'after_title' => '</div>', 'before_widget' => '<div id="%1$s" class="widget %2$s">', 'after_widget' => '</div>')); } } foreach ($this->sidebars as $theme_sidebar) { register_sidebar($theme_sidebar); } }
<!-- End Theme Custom CSS --> <!-- Theme Custom JS --> <script type="text/javascript"> jQuery(document).ready(function($) { <?php echo theme_options('advance', 'custom_js'); ?> }); </script> <!-- End Theme Custom JS --> <!-- Google Web Font --> <?php // Font to Apply $google_font = theme_options('font', 'google_web_font'); if ($google_font != '') { // Apply List $apply_lists = array('h1, h2, h3, h4, h5, h6, .widget-title, .callout-text, #primary-nav, .feature-title, .stack-title, .slide-title, .row-title'); $site_wide_active_selector = ''; $site_wide_loading_selector = ''; $site_wide_inactive_selector = ''; foreach ($apply_lists as $apply_list) { $site_wide_active_selector .= '.wf-active ' . $apply_list . ','; $site_wide_loading_selector .= '.wf-loading ' . $apply_list . ', '; $site_wide_inactive_selector .= '.wf-inactive ' . $apply_list . ', '; } $site_wide_active_selector = rtrim($site_wide_active_selector, ','); $site_wide_loading_selector = rtrim($site_wide_loading_selector, ','); $site_wide_inactive_selector = rtrim($site_wide_loading_selector, ','); ?>
_e('options saved', 'theme_admin'); ?> </div> </div> </form> </div> <!-- #theme-box-wrap --> <?php if (theme_options('advance', 'show_debug') == 'on') { ?> <section id="debug-section"> <textarea rows="20" cols="50"><?php var_dump(theme_options()); ?> </textarea> </section> <?php } ?> <?php // Autosave if (isset($_GET['save'])) { ?> <script type="text/javascript"> jQuery(document).ready(function($) { $('#theme-options-save').trigger('click'); });
} ?> </a> <div class="article-body"> <?php the_excerpt(); ?> <?php if (theme_options('blog', 'read_more_text')) { ?> <p><a href="<?php the_permalink(); ?> "><?php echo theme_options('blog', 'read_more_text'); ?> </a></p> <?php } ?> </div> </article> <?php } } else { ?> <?php _e('Sorry, nothing Found', 'theme_front');