_x( 'Accordions', 'Post Type General Name', 'tcaccordion' ), 'singular_name' => _x( 'Accordion', 'Post Type Singular Name', 'tcaccordion' ), 'menu_name' => __( 'Accordion', 'tcaccordion' ), 'name_admin_bar' => __( 'Accordion', 'tcaccordion' ), 'archives' => __( 'Item Archives', 'tcaccordion' ), 'attributes' => __( 'Item Attributes', 'tcaccordion' ), 'parent_item_colon' => __( 'Parent Item:', 'tcaccordion' ), 'all_items' => __( 'All Accordions', 'tcaccordion' ), 'add_new_item' => __( 'Add New Accordion', 'tcaccordion' ), 'add_new' => __( 'Add New Accordion', 'tcaccordion' ), 'new_item' => __( 'New Item Accordion', 'tcaccordion' ), 'edit_item' => __( 'Edit Accordion', 'tcaccordion' ), 'update_item' => __( 'Update Accordion', 'tcaccordion' ), 'view_item' => __( 'View Accordion', 'tcaccordion' ), 'view_items' => __( 'View Accordions', 'tcaccordion' ), 'search_items' => __( 'Search Accordion', 'tcaccordion' ), 'not_found' => __( 'Accordion Not found', 'tcaccordion' ), 'not_found_in_trash' => __( 'Accordion Not found in Trash', 'tcaccordion' ), 'featured_image' => __( '', 'tcaccordion' ), 'set_featured_image' => __( 'Set featured image', 'tcaccordion' ), 'remove_featured_image' => __( 'Remove featured image', 'tcaccordion' ), 'use_featured_image' => __( 'Use as featured image', 'tcaccordion' ), 'insert_into_item' => __( 'Insert into item', 'tcaccordion' ), 'uploaded_to_this_item' => __( 'Uploaded to this item', 'tcaccordion' ), 'items_list' => __( 'Items list', 'tcaccordion' ), 'items_list_navigation' => __( 'Items list navigation', 'tcaccordion' ), 'filter_items_list' => __( 'Filter items list', 'tcaccordion' ), ); $args = array( 'label' => __( 'Accordion', 'tcaccordion' ), 'description' => __( 'Accordion Post Type Description', 'tcaccordion' ), 'labels' => $labels, 'supports' => array( 'title'), 'menu_icon' => CUSTOM_ACCORDION_PLUGIN_PATH.'/css/accordion.png', 'hierarchical' => false, 'public' => true, 'show_ui' => true, 'show_in_menu' => true, 'show_in_admin_bar' => true, 'show_in_nav_menus' => true, 'can_export' => true, 'has_archive' => true, 'exclude_from_search' => false, 'publicly_queryable' => true, 'capability_type' => 'page', ); register_post_type( 'accordion_tp', $args ); } add_action( 'init', 'custom_accordion_post_register', 0 ); /*========================================================================== Adds a box to the main column on the Post and Page edit screens ==========================================================================*/ function custom_accordion_wordpress_add_custom_box() { $screens = array( 'accordion_tp' ); foreach ( $screens as $screen ){ add_meta_box('accordion_sectionid', __( 'Accordion Configure','tcaccordion' ),'custom_accordion_wordpress_inner_custom_box', $screen); } } add_action( 'add_meta_boxes', 'custom_accordion_wordpress_add_custom_box' ); /*========================================================================== Prints the box content ==========================================================================*/ function custom_accordion_wordpress_inner_custom_box() { global $post; // Use nonce for verification wp_nonce_field( plugin_basename( __FILE__ ), 'custom_accordion_wordpress_dynamicMeta_noncename' ); ?> ID, 'custom_accordion_columns_post_themes', true ); $custom_accordion_title_bg_color = get_post_meta( $post->ID, 'custom_accordion_title_bg_color', true ); $custom_accordion_title_font_color = get_post_meta( $post->ID, 'custom_accordion_title_font_color', true ); $custom_accordion_title_font_size = get_post_meta( $post->ID, 'custom_accordion_title_font_size', true ); $custom_accordion_content_bg_color = get_post_meta( $post->ID, 'custom_accordion_content_bg_color', true ); $custom_accordion_content_font_color = get_post_meta( $post->ID, 'custom_accordion_content_font_color', true ); $custom_accordion_content_font_size = get_post_meta( $post->ID, 'custom_accordion_content_font_size', true ); $custom_accordion_content_padding = get_post_meta( $post->ID, 'custom_accordion_content_padding', true ); $_tpaccpro_wiki_acc_themes_title_position = get_post_meta( $post->ID, '_tpaccpro_wiki_acc_themes_title_position', true ); $_tpaccpro_wiki_acc_themes_show_hide_icons = get_post_meta( $post->ID, '_tpaccpro_wiki_acc_themes_show_hide_icons', true ); $_tpaccpro_wiki_acc_themes_icon_position = get_post_meta( $post->ID, '_tpaccpro_wiki_acc_themes_icon_position', true ); $_tpaccpro_wiki_acc_theme_content_margin = get_post_meta( $post->ID, '_tpaccpro_wiki_acc_theme_content_margin', true ); ?>