Site logo

Archived topic

ERROR FOOTER - DISPATCH THEME

1 reply · Started by josepdlh on September 18, 2020

Viewing posts 1–2 of 2

Hello,

I'm using the dispatch theme and suddenly the footer buttons (to go the previous or next post) appears with and error only in the mobile version:

https://ibb.co/Nj42CQp

Thanks

Hi,

I've checked your site and noticed that part of your PHP code is commented out.
commented out php

<!--?php this part has to be fixed into <?php for the PHP snippet to work.

Or if you actually intend to comment everything out, you can do this instead.

/*
<?php
                wp_reset_postdata();
            } //end foreach
        } // end if
         
        $nextPost = get_next_post(false);
        if($nextPost) {
            $args = array(
                'posts_per_page' = 1,
                'include' => $nextPost->ID
            );
            $nextPost = get_posts($args);
            foreach ($nextPost as $post) {
                setup_postdata($post);
?>
*/

It's basically using the /* [code here] */ comment syntax for PHP.

This archived topic is closed to new replies.