Open Frumph opened 5 years ago
$chapter_on_home = ''; $chapter_on_home = get_term_by( 'id', ceo_pluginfo('chapter_on_home'), 'chapters'); $chapter_on_home = (!is_wp_error($chapter_on_home) && !empty($chapter_on_home)) ? $chapter_on_home->slug : ''; $order = (ceo_pluginfo('display_first_comic_on_home_page')) ? 'asc' : 'desc'; $comic_args = array( 'showposts' => 1, 'posts_per_page' => 1, 'post_type' => 'comic', 'order' => $order, 'chapters' => $chapter_on_home ); $comicFrontpage = new WP_Query(); $comicFrontpage->query($comic_args); while ($comicFrontpage->have_posts()) : $comicFrontpage->the_post(); needs to replace whatever is there so that a single chapter can appear on home
$chapter_on_home = ''; $chapter_on_home = get_term_by( 'id', ceo_pluginfo('chapter_on_home'), 'chapters'); $chapter_on_home = (!is_wp_error($chapter_on_home) && !empty($chapter_on_home)) ? $chapter_on_home->slug : ''; $order = (ceo_pluginfo('display_first_comic_on_home_page')) ? 'asc' : 'desc'; $comic_args = array( 'showposts' => 1, 'posts_per_page' => 1, 'post_type' => 'comic', 'order' => $order, 'chapters' => $chapter_on_home ); $comicFrontpage = new WP_Query(); $comicFrontpage->query($comic_args); while ($comicFrontpage->have_posts()) : $comicFrontpage->the_post();
frick the code display not working but find the main code in the injections.php and put it in the navigation.php
$chapter_on_home = ''; $chapter_on_home = get_term_by( 'id', ceo_pluginfo('chapter_on_home'), 'chapters'); $chapter_on_home = (!is_wp_error($chapter_on_home) && !empty($chapter_on_home)) ? $chapter_on_home->slug : ''; $order = (ceo_pluginfo('display_first_comic_on_home_page')) ? 'asc' : 'desc'; $comic_args = array( 'showposts' => 1, 'posts_per_page' => 1, 'post_type' => 'comic', 'order' => $order, 'chapters' => $chapter_on_home ); $comicFrontpage = new WP_Query(); $comicFrontpage->query($comic_args); while ($comicFrontpage->have_posts()) : $comicFrontpage->the_post();
needs to replace whatever is there so that a single chapter can appear on home