Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    Honestly, CMB2 is more a library to create metabox UI to be used for keying in and storing the data more than anything. What it sounds like you most need is just a way to take that “today+3 weeks” and various future iterations to calculate say a UTC timestamp and whatnot to be stored.

    Even with using a field from CMB2, you’d need to calculate that value ahead of time to be passed to the WordPress meta field functions, as well as do something with it in your templates.

    Thread Starter Floris

    (@flo80)

    Thank you for your quick reply!
    Is my request that out of the ordinary that this is not easily done? I’m wondering if I’m even taking the right approach or if there’s an easier way.

    Plugin Contributor Michael Beckwith

    (@tw2113)

    The BenchPresser

    It’s not that it can’t be done, it’s just that CMB2 doesn’t have any functionality specific to this request outside of generating UI in the admin to type in a value. With the dynamic-ness of the topic and incoming data, you wouldn’t want to be typing it in manually, it’d be better to set up automation to calculate and store data as it comes rolling in regularly. No UI needed for that.

    If you wanted a spot to see the current value, and perhaps manually touch up the result, in some way, then CMB2 could be of value. The only other way I can think of CMB2 being of use would be if you’re calculating the date to use manually as well, but that’d take out the dynamic-ness of it all

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.