Mobile da camera – Falegnameria Alcastagno – Rivera – Rolando Picchetti
Mobile da camera – Falegnameria Alcastagno – Rivera – Rolando Picchetti
add_action( 'wp_enqueue_scripts', 'enqueue_parent_theme_style' ); function enqueue_parent_theme_style() { wp_enqueue_style( 'parent-style', get_template_directory_uri().'/style.css' ); } function change_gallery_width() {return "1140";} add_filter('tiled_gallery_content_width', change_gallery_width,10,3); //FUNZIONI PER PRENDERE QUESTI DUE FILE DAL TEMA FIGLIO INVECE CHE DAL PADRE // Extend Projects function infinity_require_project_extendC() { require_once get_theme_root() . '/tm-wood-worker-child/inc/project-extendC.php'; } add_action('init', 'infinity_require_project_extendC', 15); flush_rewrite_rules(); // Extend Projects function infinity_require_project_extendCd() { require_once get_theme_root() . '/tm-wood-worker-child/inc/project-extend.php'; } add_action('init', 'infinity_require_project_extendCd', 15); flush_rewrite_rules(); //RINOMINARE SLUG PROJECT IN PROGETTI //function change_slug_of_post_type_projects() { //$args = get_post_type_object("project"); //$args->rewrite["slug"] = "progetti"; //register_post_type($args->name, $args); //} //add_action('init', 'change_slug_of_post_type_projects', 20); //--------------------------------------------- /* Meta box aggiunto sui progetti */ add_action( 'add_meta_boxes', 'st_add_options_project' ); function st_add_options_project() { $screens = array( 'project'); foreach ( $screens as $screen ) { add_meta_box( 'st_project_options', // Unique ID 'Sotto titolo', // Box title 'st_add_html_options_project', // Content callback descritta sotto $screen // post type ); } } //Richiamo callback descritta sopra nella funzione per aggiungere i metabox function st_add_html_options_project( $post ) { $value1 = get_post_meta( $post->ID, 'st-sottotitolo', true ); echo '
'; } if ( isset($_POST['conc_meta_form']) and $_POST['conc_meta_form'] == 1 ) { add_action( 'save_post', 'st_options_project_save_postdata' ); function st_options_project_save_postdata( $post_id ) { if( defined( 'DOING_AUTOSAVE' ) && DOING_AUTOSAVE ) return; if (empty($_POST['sottotitolo'])){ $_POST['sottotitolo'] = "";} update_post_meta( $post_id,'st-sottotitolo',$_POST['sottotitolo']); }} //AGGIUNTO CSS IN ADMIN function load_custom_wp_admin_styl_css() { wp_register_style( 'custom-admin', get_stylesheet_directory_uri() . '/css/customStyle.css', false, '' ); wp_enqueue_style( 'custom-admin' ); } add_action( 'admin_enqueue_scripts', 'load_custom_wp_admin_styl_css' );Mobile da camera – Falegnameria Alcastagno – Rivera – Rolando Picchetti