1 | <?php |
||||||
2 | /** |
||||||
3 | * The template for the "Draft" story pages |
||||||
4 | * |
||||||
5 | * Archive comic stories without a taxonomy_term set. |
||||||
6 | * Using custom Taxonomy "draft" http://codex.wordpress.org/Template_Tags/get_posts#Taxonomy_Parameters |
||||||
7 | * |
||||||
8 | * @link https://codex.wordpress.org/Template_Hierarchy |
||||||
9 | * |
||||||
10 | * @package WordPress |
||||||
11 | * @subpackage Strip |
||||||
12 | */ |
||||||
13 | |||||||
14 | get_header(); ?> |
||||||
0 ignored issues
–
show
Bug
introduced
by
![]() |
|||||||
15 | |||||||
16 | <div id="primary" |
||||||
17 | <main id="content" class="wrap" role="main"> |
||||||
18 | |||||||
19 | <?php if ( have_posts() ) : ?> |
||||||
0 ignored issues
–
show
The function
have_posts was not found. Maybe you did not declare it correctly or list all dependencies?
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
![]() |
|||||||
20 | <header class="page-header"> |
||||||
21 | </br> |
||||||
22 | <?php |
||||||
23 | // Show an optional term description. |
||||||
24 | $term_description = term_description(); |
||||||
0 ignored issues
–
show
The function
term_description was not found. Maybe you did not declare it correctly or list all dependencies?
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
![]() |
|||||||
25 | if ( ! empty( $term_description ) ) : |
||||||
26 | printf( '<div class="taxonomy-description">%s</div>', $term_description, 'strip' ); // WPCS: XSS OK. |
||||||
27 | endif; ?> |
||||||
28 | <h4 class="comic-blurb">Here are your uncategorized comics. To order them, go to Add New Comic, then + Add New Story and write a series title of your choice, or check an existing series box, if you had one. To write your own custom taxonomies, clone taxonomy-story-draft.php and replace "draft" by your own story name.</h4> |
||||||
29 | </header><!-- .page-header --> |
||||||
30 | |||||||
31 | <?php // Create and run first loop in reverse order. |
||||||
32 | $comic = new WP_Query(); |
||||||
0 ignored issues
–
show
The type
WP_Query was not found. Maybe you did not declare it correctly or list all dependencies?
The issue could also be caused by a filter entry in the build configuration.
If the path has been excluded in your configuration, e.g. filter:
dependency_paths: ["lib/*"]
For further information see https://scrutinizer-ci.com/docs/tools/php/php-scrutinizer/#list-dependency-paths ![]() |
|||||||
33 | $comic->query( array( |
||||||
34 | 'post_type' => 'comic', |
||||||
35 | 'showposts' => -1, |
||||||
36 | 'story' => 'draft', |
||||||
37 | 'orderby' => 'title', // You can also order by date, like regular posts. |
||||||
38 | 'order' => 'DESC', // It is either ASC or DESC, standing for ascendant or descendant order. |
||||||
39 | ) |
||||||
40 | ); |
||||||
41 | |||||||
42 | while ( $comic->have_posts() ) : $comic->the_post(); |
||||||
43 | |||||||
44 | get_template_part( 'content-comic' ); ?> |
||||||
0 ignored issues
–
show
The function
get_template_part was not found. Maybe you did not declare it correctly or list all dependencies?
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
![]() |
|||||||
45 | |||||||
46 | <?php endwhile; ?> |
||||||
47 | <?php |
||||||
48 | wp_reset_postdata(); |
||||||
0 ignored issues
–
show
The function
wp_reset_postdata was not found. Maybe you did not declare it correctly or list all dependencies?
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
![]() |
|||||||
49 | ?> |
||||||
50 | <?php else : ?> |
||||||
51 | |||||||
52 | <?php get_template_part( 'no-results', 'archive-comic' ); ?> |
||||||
53 | |||||||
54 | <?php endif; ?> |
||||||
55 | |||||||
56 | </main><!-- #content --> |
||||||
57 | </section><!-- #primary --> |
||||||
58 | <?php get_footer(); ?> |
||||||
0 ignored issues
–
show
The function
get_footer was not found. Maybe you did not declare it correctly or list all dependencies?
(
Ignorable by Annotation
)
If this is a false-positive, you can also ignore this issue in your code via the
![]() |
|||||||
59 |