1er commit
This commit is contained in:
34
functions.php
Normal file
34
functions.php
Normal file
@@ -0,0 +1,34 @@
|
||||
<?php
|
||||
/* enqueue scripts and style from parent theme */
|
||||
function yuzu_styles() {
|
||||
//wp_enqueue_style( 'parent', get_template_directory_uri() . '/style.css' );
|
||||
|
||||
$parent_style = 'parent'; // This is 'twentyfifteen-style' for the Twenty Fifteen theme.
|
||||
|
||||
wp_enqueue_style( $parent_style, get_template_directory_uri() . '/style.css' );
|
||||
wp_enqueue_style( 'child-style',
|
||||
get_stylesheet_directory_uri() . '/style.css',
|
||||
array( $parent_style ),
|
||||
wp_get_theme()->get('Version')
|
||||
);
|
||||
|
||||
}
|
||||
add_action( 'wp_enqueue_scripts', 'yuzu_styles');
|
||||
|
||||
// Modifier le seuil à 3200px:
|
||||
add_filter( 'big_image_size_threshold', 'modify_big_image_size_threshold', 10, 4 );
|
||||
function modify_big_image_size_threshold( $threshold, $imagesize, $file, $attachment_id ) {
|
||||
return 4096;
|
||||
}
|
||||
|
||||
// Désactiver complètement le seuil maximum:
|
||||
//add_filter( 'big_image_size_threshold', '__return_false' );
|
||||
|
||||
// Infos sur les tailles d’images actives:
|
||||
//add_action( 'admin_init', 'theme_additional_images' );
|
||||
function theme_additional_images() {
|
||||
global $_wp_additional_image_sizes;
|
||||
echo '<pre>' . print_r($_wp_additional_image_sizes) . '</pre>';
|
||||
}
|
||||
|
||||
?>
|
||||
Reference in New Issue
Block a user