Use dedicated functions

You’ll want to enqueue the script in your functions.php (If this is in a plugin, you could do a little differently). Here’s a sample: function owl_scripts() { wp_enqueue_script( ‘owl-carousel’, get_stylesheet_directory_uri() . ‘js/carousel.js’, array( ‘jquery’ ), ”, true ); wp_enqueue_style( ‘owl-style-min’, get_stylesheet_directory_uri() . ‘css/carousel.css’ ); } add_action( ‘wp_enqueue_scripts’, ‘owl_scripts’ ); This is assuming: You’re using a … Read more

Display Parent-Child Posts in specific order by comparing IDs in array

I think you’ll just need to loop the loop and first build a helper array to contain the hierarchy, then work with that to print out any necessary html. Caching the resulting helper array to a transient might be a good idea to save processing time. // is there a transient? $transient = get_transient( “parent_children_ids_{$post_id}” … Read more