• Resolved gulliver

    (@gulliver)


    What does if ‘&& ! is_404()’ mean in the context of:

    if ( ( $paged >= 2 || $page >= 2 ) && ! is_404() )

Viewing 2 replies - 1 through 2 (of 2 total)
  • Moderator keesiemeijer

    (@keesiemeijer)

    the ! means IS NOT, and && means AND
    https://secure.php.net/manual/en/language.operators.logical.php

    So the first conditional (between Round round brackets) is
    if ( $paged >= 2 OR $page >= 2 )
    And the second is
    AND IS NOT is_404()

    It checks if the $paged or $page variables are greater or equal to two, and if it’s not a 404 page. The whole conditional will always return false on 404 pages regardless of the first condition.

    Thread Starter gulliver

    (@gulliver)

    Thanks. Appreciated.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘What does this code mean?’ is closed to new replies.