These results are based on our legacy PHP analysis, consider migrating to our new PHP analysis engine instead. Learn more
1 | <?php |
||
2 | /** |
||
3 | * The template for displaying all single posts. |
||
4 | * |
||
5 | * @link https://developer.wordpress.org/themes/basics/template-hierarchy/#single-post |
||
6 | * |
||
7 | * @package Lighthouse |
||
8 | */ |
||
9 | |||
10 | get_header(); ?> |
||
11 | |||
12 | <div class="title-wrapper"> |
||
13 | <div class="container blog-wrapper"> |
||
14 | <div class="row"> |
||
15 | <div class="col-xs-12"> |
||
16 | <h1 class="entry-title">Lighthouse News Centre</h1> <div class="back-to"> <span> | </span><a href="<?php echo get_site_url(); ?>/news-centre">back</a></div> |
||
17 | </div> |
||
18 | </div> |
||
19 | </div> |
||
20 | </div> |
||
21 | <div id="primary" class="container content-area wider-wrapper"> |
||
22 | <div class="row"> |
||
23 | <div class="col-md-9 content-listing"> |
||
24 | <main id="main" class="site-main" role="main"> |
||
25 | |||
26 | <?php |
||
27 | while ( have_posts() ) : the_post(); |
||
28 | |||
29 | $thumb_feature = wp_get_attachment_image_src( get_post_thumbnail_id(), 'lighthouse_feature_img'); |
||
30 | $url_feature = $thumb_feature[0]; |
||
31 | ?> |
||
32 | |||
33 | <div class="post-img"> |
||
34 | <img class="img-responsive" src="<?php echo $url_feature; ?>"> |
||
35 | </div> |
||
36 | |||
37 | <?php |
||
38 | get_template_part( 'template-parts/content', get_post_format() ); |
||
39 | |||
40 | //the_post_navigation(); |
||
41 | |||
42 | // If comments are open or we have at least one comment, load up the comment template. |
||
43 | // if ( comments_open() || get_comments_number() ) : |
||
0 ignored issues
–
show
|
|||
44 | // comments_template(); |
||
45 | // endif; |
||
46 | |||
47 | endwhile; // End of the loop. |
||
48 | ?> |
||
49 | |||
50 | </main><!-- #main --> |
||
51 | |||
52 | <div class="row disclaimer-box"> |
||
53 | <div class="disclaimer-icon"><i class="fa fa-info"></i></div> |
||
54 | <div id="disclaimer-text" class="readmore">Disclaimer: This article is for your general information and use only and is not intended to address your particular requirements. |
||
55 | It should not be relied upon in its entirety. Although endeavours have been made to provide accurate and timely information, |
||
56 | there can be no guarantee that such information is accurate as of the date it is received or that it will continue to be accurate in the future. |
||
57 | No individual or company should act upon such information without receiving appropriate professional advice after a thorough examination of their particular situation. |
||
58 | Levels, bases of and reliefs from taxation are subject to change and their value depends on the individual circumstances of the investor. |
||
59 | The past performance of an investment provides no guarantee as to the future performance of the new funds. |
||
60 | The value of unit prices can fall as well as rise and the return of your capital is not guaranteed. |
||
61 | Tax advice which contains no investment element is not regulated by the Financial Conduct Authority. |
||
62 | </div> |
||
63 | </div> |
||
64 | |||
65 | <div class="post-slider row"> |
||
66 | <h2>Related Artices</h2> |
||
67 | <div id="related-posts" class="owl-carousel"> |
||
68 | <?php |
||
69 | $postslist = get_posts('numberposts=99&order=DESC&orderby=date'); |
||
70 | foreach ($postslist as $post) : |
||
71 | setup_postdata($post); |
||
72 | ?> |
||
73 | <div class="col-xs-12"> |
||
74 | <div class="entry"> |
||
75 | |||
76 | <div class="thumbnail thumbnail-hover"> |
||
77 | <?php |
||
78 | $thumb_post = wp_get_attachment_image_src( get_post_thumbnail_id(), 'lighthouse_related_post'); |
||
79 | $url_post = $thumb_post[0]; |
||
80 | ?> |
||
81 | <img class="img-responsive" src="<?php echo $url_post; ?>"> |
||
82 | <a href="<?php the_permalink() ?>" title="<?php the_title_attribute() ?>" class="overlay"></a> |
||
83 | </div> |
||
84 | |||
85 | <h3><a href="<?php the_permalink(); ?>"><?php the_title(); ?></a></h3> |
||
86 | <span class="date"> |
||
87 | <i class="fa fa-clock-o"></i> |
||
88 | <?php the_time(get_option('date_format')) ?> |
||
89 | </span> |
||
90 | </div> |
||
91 | </div> |
||
92 | <?php endforeach; ?> |
||
93 | |||
94 | </div> |
||
95 | </div> |
||
96 | |||
97 | |||
98 | </div><!-- .blog-listing --> |
||
99 | <div class="col-md-3 sidebar" role="complementary"> |
||
100 | <?php dynamic_sidebar( 'blog_widgets' ); ?> |
||
101 | </div> |
||
102 | </div><!-- .row --> |
||
103 | </div><!-- #primary --> |
||
104 | |||
105 | <?php |
||
106 | get_sidebar(); |
||
107 | get_footer(); |
||
108 |
Sometimes obsolete code just ends up commented out instead of removed. In this case it is better to remove the code once you have checked you do not need it.
The code might also have been commented out for debugging purposes. In this case it is vital that someone uncomments it again or your project may behave in very unexpected ways in production.
This check looks for comments that seem to be mostly valid code and reports them.