Support

Account

Home Forums Gutenberg If the last block is a certain block, hide something in footer.php

Unread

If the last block is a certain block, hide something in footer.php

  • Basically, I want to have a code that looks to see if the last block on a page is a certain block type, let’s say banner.

    If the last block is banner, I want to hide a section of code in the footer.php. I saw a similar code snippet for the first block on the page, but couldn’t figure out how to engineer this to work in this use-case. Ideas?

Viewing 1 post (of 1 total)

You must be logged in to reply to this topic.