require_once(TEMPLATEPATH . '/epanel/custom_functions.php'); require_once(TEMPLATEPATH . '/includes/functions/comments.php'); require_once(TEMPLATEPATH . '/includes/functions/sidebars.php'); load_theme_textdomain('InStyle',get_template_directory().'/lang'); require_once(TEMPLATEPATH . '/epanel/options_instyle.php'); require_once(TEMPLATEPATH . '/epanel/core_functions.php'); require_once(TEMPLATEPATH . '/epanel/post_thumbnails_instyle.php'); function register_main_menus() { register_nav_menus( array( 'primary-menu' => __( 'Primary Menu' ) ) ); } if (function_exists('register_nav_menus')) add_action( 'init', 'register_main_menus' ); function et_create_dropcaps($post_text){ global $shortname; if ( get_option($shortname . '_dropcaps') == 'false' ) return $post_text; $post_content_text = trim($post_text); $post_content_temp = trim(strip_tags($post_text)); # don't create drop-cap if shortcodes is on top of the post content if ( $post_content_temp[0] == '[' || $post_content_temp == '' ) return $post_text; else { //get first 7 letters $first_word = mb_substr($post_content_temp, 0, 7, 'UTF-8'); } $first_word_pos = strpos($post_content_text, $first_word); if ( $first_word_pos === false ) return $post_text; $post_content_firstletter = mb_substr($post_content_text, $first_word_pos, 1, 'UTF-8'); if ( $first_word_pos == 0 ) $post_content_text_temp = ''; else $post_content_text_temp = mb_substr($post_content_text, 0, $first_word_pos-1, 'UTF-8'); $post_content_text_temp2 = mb_substr($post_content_text, $first_word_pos+1, strlen($post_content_text), 'UTF-8'); return '' . $post_content_firstletter . '' . $post_content_text_temp . $post_content_text_temp2; } add_action('wp_head','et_add_meta_javascript'); function et_add_meta_javascript(){ global $shortname; echo ''; echo ''; echo ''; $disable_toptier = get_option($shortname.'_disable_toptier') == 'on' ? 1 : 0; echo ''; $cufon = get_option($shortname.'_cufon') == 'on' ? 1 : 0; echo ''; } add_filter('body_class','et_cufon_class'); function et_cufon_class($classes) { global $shortname; if ( get_option($shortname.'_cufon') == 'false' ) $classes[] = 'cufon-disabled'; return $classes; } require_once(TEMPLATEPATH . '/includes/additional_functions.php'); $wp_ver = substr($GLOBALS['wp_version'],0,3); if ($wp_ver >= 2.8) include(TEMPLATEPATH . '/includes/widgets.php'); ?>