ID, ARRAY_A); $slug = $post_data['post_name']; return $slug; } function excerpt() { add_post_type_support( 'page', 'excerpt' ); } add_action('init', 'excerpt'); function excerpt_l($length) { return 30; } add_filter('excerpt_length', 'excerpt_l',999); function excerpt_m($more) { return 'Continua'; } add_filter('excerpt_more', 'excerpt_m'); if ( !isset( $content_width ) ) $content_width = 515; if(function_exists('automatic-feed-links')) { add_theme_support('automatic-feed-links'); } // threaded comments function enable_threaded_comments(){ if (!is_admin()) { if (is_singular() AND comments_open() AND (get_option('thread_comments') == 1)) wp_enqueue_script('comment-reply'); } } add_action('get_header', 'enable_threaded_comments'); // Custom menu support if (function_exists('register_nav_menus')) { register_nav_menus ( array ( 'main' => __('Sidebar main'), 'secondary' => __('Sidebar secondary'), ) ); } // load jquery if not admin page if (!is_admin()) {wp_enqueue_script('jquery');} // dont load jquery in 404 template function remove_404_jquery(){ if (is_404() ) { wp_deregister_script('jquery'); } } add_action('wp_enqueue_scripts', 'remove_404_jquery', 15); remove_action('wp_head','qtrans_header'); remove_action('wp_head','wp_cycle_style'); remove_action('wp_head','wp_generator'); remove_action('wp_head','wlwmanifest_link'); remove_action('wp_head','index_rel_link'); remove_action('wp_head','rsd_link'); remove_action('wp_head','feed_links',2); remove_action('wp_head','index_rel_link'); remove_action('wp_head','feed_links_extra',3); remove_action('wp_head','start_post_rel_link',10,0); remove_action('wp_head','parent_post_rel_link',10,0); remove_action('wp_head','adjacent_posts_rel_link',10,0); remove_action('wp_head','rel_canonical'); remove_action('wp_head','wp_shortlink_wp_head', 10,0); remove_action('template_redirect','wp_shortlink_header',11,0); remove_action('wp_head','start_post_rel_link',10,0 ); remove_action('wp_head','adjacent_posts_rel_link_wp_head',10,0); function admin_favicon() { echo ''; } add_action('admin_head', 'admin_favicon'); if (!is_admin()) { function rml10n() { wp_deregister_script('l10n'); } add_action('init', 'rml10n'); } function add_menuid ($page_markup) { preg_match('/^