// Char limit for the news on the homepage function fix_the_excerpt($text) { return str_replace('[...]', '...', $text); } add_filter('the_excerpt', 'fix_the_excerpt'); function my_excerpt_length($length) { return 16; } add_filter('excerpt_length', 'my_excerpt_length'); // Allow SVG upload function cc_mime_types($mimes) { $mimes['svg'] = 'image/svg+xml'; return $mimes; } add_filter('upload_mimes', 'cc_mime_types'); // Register Supplier Post Type function suppliers() { $args = array( 'label' => __('Suppliers'), 'singular_label' => __('Supplier'), 'public' => true, 'show_ui' => true, '_builtin' => false, '_edit_link' => 'post.php?post=%d', 'capability_type' => 'post', 'hierarchical' => false, 'rewrite' => array("slug" => "suppliers"), 'supports' => array('title', 'editor', 'thumbnail') ); register_post_type( 'suppliers' , $args ); register_taxonomy_for_object_type('post_tag', 'suppliers','show_tagcloud=1&hierarchical=true'); } add_action('init', 'suppliers'); if ( function_exists( 'add_theme_support' ) ) { add_theme_support( 'post-thumbnails' ); } ?>