__( 'Top Menu', 'foliogine' ),
) );
}
add_action( 'after_setup_theme', 'cwp_theme_setup' );
function cwp_register_custom_background() {
$args = array(
'default-color' => 'ffffff',
'default-image' => '',
);
$args = apply_filters( 'themeisle_theme_custom_background_args', $args );
add_theme_support( 'custom-background', $args );
}
add_action( 'after_setup_theme', 'cwp_register_custom_background' );
/**
* Register widgetized area and update sidebar with default widgets
*/
function cwp_widgets_init() {
register_sidebar( array(
'name' => __( 'Sidebar', 'foliogine' ),
'id' => 'sidebar-1',
'before_widget' => '',
'before_title' => '
',
) );
}
add_action( 'widgets_init', 'cwp_widgets_init' );
/**
* Enqueue scripts and styles
*/
function cwp_scripts() {
wp_enqueue_style( 'cwp-style', get_stylesheet_uri() );
wp_enqueue_script('jquery');
wp_enqueue_script( 'sharrre', get_template_directory_uri() . '/js/jquery.sharrre-1.3.4.js', array("jquery"), '20120206', true );
wp_enqueue_script( 'jqcycle', get_template_directory_uri() . '/js/jqcycle.min.js', array(), '20120206', true );
wp_enqueue_script( 'cwp-navigation', get_template_directory_uri() . '/js/navigation.js', array(), '20120206', true );
wp_enqueue_script( 'bootstrap', get_template_directory_uri() . '/js/bootstrap.min.js', array("jquery"), '20120206', true );
wp_enqueue_script( 'tabs', get_template_directory_uri() . '/js/tabs.js', array("jquery"), '20120206', true );
wp_enqueue_script( 'tinynav', get_template_directory_uri() . '/js/tinynav.min.js', array("jquery"), '20120206', true );
wp_enqueue_script( 'customscript', get_template_directory_uri() . '/js/customscript.js', array("jquery","jqcycle","sharrre","tinynav"), '20120206', true );
wp_enqueue_script( 'retina', get_template_directory_uri() . '/js/retina.js', array("jquery"), '20120206', true );
wp_enqueue_script( 'slider', get_template_directory_uri() . '/js/jquery.bxslider.min.js', array("jquery"), '20120206', true );
wp_enqueue_script( 'skills', get_template_directory_uri() . '/js/jquery.donutchart.js', array("jquery"), '20120206', true );
wp_register_style( 'php-style', get_template_directory_uri() . '/css/style.php');
wp_enqueue_style( 'php-style' );
if ( is_singular() && comments_open() && get_option( 'thread_comments' ) ) {
wp_enqueue_script( 'comment-reply' );
}
if ( is_singular() && wp_attachment_is_image() ) {
wp_enqueue_script( 'cwp-keyboard-image-navigation', get_template_directory_uri() . '/js/keyboard-image-navigation.js', array( 'jquery' ), '20120202' );
}
if (current_user_can( 'manage_options' )) {
wp_register_style('cwp_admin_css', get_template_directory_uri() . '/css/admin.css', array(), '1.0', 'all');
wp_enqueue_style('cwp_admin_css');
}
}
add_action( 'wp_enqueue_scripts', 'cwp_scripts' );
add_theme_support( 'post-thumbnails' );
/**
* Implement the Custom Header feature
*/
require( get_template_directory() . '/inc/custom-header.php' );
include("shortcodes.php");
add_filter('widget_text', 'do_shortcode');
add_image_size( 'blog-small', 444, 446, true );
add_image_size( 'blog-large', 616, 613, true );
add_image_size( 'portofolio-thumb', 252, 162, true );
add_image_size( 'portofolio-large', 912,387, true );
add_image_size( 'our-team-photo', 228, 230, true );
function cwp_comment($comment, $args, $depth) {
$GLOBALS['comment'] = $comment;
if ( 'div' == $args['style'] ) {
$tag = 'div';
$add_below = 'comment';
} else {
$tag = 'li';
$add_below = 'div-comment';
}
?>
'.do_shortcode($content).'';
return $output;
}
add_shortcode("tabs_names", "cwp_tabs_names");
function cwp_tab($atts, $content = null) {
extract(shortcode_atts(array(
'id' => '',
'title' => '',
'active'=>'n'
), $atts));
if (empty($id))
$id = 'tab_item_'.rand(100,999);
$output = '
'.$title.'
';
return $output;
}
add_shortcode("tab", "cwp_tab");
function cwp_tabs_contents($atts, $content = null) {
$output = ''.do_shortcode($content).'
';
return $output;
}
add_shortcode("tabs_contents", "cwp_tabs_contents");
function cwp_content($atts, $content = null) {
extract(shortcode_atts(array(
'id' => '',
), $atts));
if (empty($id))
$id = 'tab_item_'.rand(100,999);
$output = ''.$content.'
';
return $output;
}
add_shortcode("content", "cwp_content");
function cwp_add_editor_styles() {
add_editor_style( '/css/custom-editor-style.css' );
}
add_action( 'init', 'cwp_add_editor_styles' );
add_filter( 'the_title', 'cwp_default_title' );
function cwp_default_title( $title ) {
if ($title == '')
$title = "Default title";
return $title;
}
By on
comment_approved == '0') : ?>