The Support Forums will be in read-only mode for a scheduled maintenance window on 01 September 2016 14:00 UTC - 20:00 UTC. More information.

Themia Lite
404 page not displaying correctly (4 posts)

  1. sandayspinner
    Posted 4 years ago #

    I have a new site using Themia Lite. I note that the theme has a 404 page file and that it is clearly intended to write some helpful text to the page... but sadly what is displayed is less than user friendly. There is nothing to identify the page as a 404 - no Page Not Found message - just a search box and a product category list.

    See here http://shop.sandayspinners.co.uk/woo/ for example


  2. MickeyRoush
    Posted 4 years ago #

    I've noticed this as well.

  3. Gary Darling
    Posted 4 years ago #

    The problem with the 404.php page is that the theme author included The Loop in it - the part that says:

    <?php if ( have_posts() ) while ( have_posts() ) : the_post(); ?>
     // All the meaningful stuff
    <?php endwhile; ?>

    Logically, this says "If there are some posts or pages that match the query then show them in the section that follows". Well, a 404 page is there for when a mistake is made and there are no posts or pages that match the query. So the section that follows never gets called, because the if returns false.

    Delete the code calling the loop as well as the 'endwhile' code and it works like a charm.

  4. MickeyRoush
    Posted 4 years ago #

    @ garydarling

    Thank you!

Topic Closed

This topic has been closed to new replies.

About this Theme

About this Topic