To add the Graphene slider into every page and post within the Graphene theme, the following code is placed into a functions.php file in the child theme.
<?php
function graphene_display_slider(){
graphene_slider();
add_action(‘wp_footer’, ‘graphene_scrollable’);
}
function custom_enqueue_scripts(){
if ( ! is_admin() ) { // Front-end only
wp_enqueue_script( ‘graphene-jquery-tools’ ); // jQuery Tools, required for slider
}
}
add_action( ‘wp_enqueue_scripts’, ‘custom_enqueue_scripts’ );
?>
The <?php and ?> codes at the start and end, are only required if this is the only code in the file
82.1 - 869,280
↓ Scroll down for Comments ↓