• Resolved André

    (@andrechaperon)


    Hi Gaurav — really nice plugin!

    I think I’ve found a small edge-case bug/formatting issue with the [year] shortcode when n is a large negative number (somewhere in the 4 digits).

    This works as expected:

    [age date="2003-01-01"]

    Expected output: 23 (and that’s what I get)

    But this doesn’t behave as expected:

    [year n=-2003]

    I’d expect this to output the current year minus 2003 (e.g., 23 in 2026), but it seems like 2003 is “too large” and something breaks once n crosses into 4 digits somewhere.

    Also, this looks like a zero-padding issue:

    [year n=-1100]

    Current output: 0926
    Expected output: 926

    Not a big deal on my end since [age date="2003-01-01"] works for my use case — just wanted to flag it in case you’d like to harden the [year] path (or strip leading zeros).

    André

    The page I need help with: [log in to see the link]

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

You must be logged in to reply to this topic.