Support » Plugin: Custom Content Shortcode » Inconsistent output from date code

  • I’m trying to put together a very simple formula that alternates content based on a date – if it’s before X, it says “story will be published”. If it’s on or after, it says “story was published”. I’ve thought I had this done several times, only to realize the output isn’t as anticipated. Now, I’m realizing it may not be me at all.

    For example, in two different posts, the same code gives different results.

    Code (same for both posts)
    “Story” [if field=date before=’2017-08-17′] will be [else] was[/if] published on 17 August 2017.
    “Story” [if field=date before=’2017-08-19′] will be [else] was[/if] published on 19 August 2017.
    “Story” [if field=date before=’2017-08-21′] will be [else] was[/if] published on 21 August 2017.

    Result 1 (draft post that has seen multiple versions, was published once by mistake)
    “Story” was published on 17 August 2017.
    “Story” was published on 19 August 2017.
    “Story” was published on 21 August 2017.

    Result 2 (code copied and pasted from above, never published, never saved)
    “Story” was published on 17 August 2017.
    “Story” was published on 19 August 2017.
    “Story” will be published on 21 August 2017.

Viewing 3 replies - 1 through 3 (of 3 total)
  • Thread Starter Evil Overlord

    (@evil-overlord)

    No response?

    Thread Starter Evil Overlord

    (@evil-overlord)

    Still nothing? Should I assume that this functionality simply doesn’t … function?

    Thread Starter Evil Overlord

    (@evil-overlord)

    Eliot,

    Good to see you back and answering questions. I wasn’t sure how far back you’d go, so I’m bumping this up with a new reply. I’d really love to use this plugin for this – haven’t found another solution to the problem.

Viewing 3 replies - 1 through 3 (of 3 total)
  • The topic ‘Inconsistent output from date code’ is closed to new replies.