Support » Themes and Templates » Detecting Preview mode

Detecting Preview mode

  • Is there a way that a theme can detect whether a post is being displayed in Preview mode (i.e. from clicking the “Preview Changes” button on the Edit Post screen), rather than on the actual public site?

    The reason is, some of my pages have “additional notes” contained in a custom text field via the Advanced Custom Fields plugin. I also have a checkbox that hides the notes from public view until I’m ready to publish them. I’d like – if possible – to make the notes always visible on the preview screen whilst still hidden to the public.

Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
  • The topic ‘Detecting Preview mode’ is closed to new replies.