• Resolved perikazo

    (@perikazo)


    Hello, I have a problem, the date and time field is not saved but the check field to delete if saved correctly, I have deactivated and reactivated plugins to avoid interference and still the same, my php version is 7.4, my time zone configured Europe/Madrid, there was a time that worked, but with the last update has stopped working this date field. Thanks for your great plugin and your help.

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

Viewing 5 replies - 1 through 5 (of 5 total)
  • Plugin Author yakacj

    (@yakacj)

    Hello,

    Sorry for delayed reply. As we checked( v.1.0.5), there is no issue and working as expected( both fields can save, and expire on selected datetime ).

    Current environment: WordPress: 6.4.3, WooCommerce: 8.5.2, PHP 7.4

    May be you need to check: Other plugins or theme. Still have issue, let us check you website (admin).

    Thanks for the time.

    • This reply was modified 9 months, 3 weeks ago by yakacj.
    Thread Starter perikazo

    (@perikazo)

    Hello friend, I think I have found the problem that the date is not saved correctly and for me this is resolved:

    class_ycve_admin.php

    Line 111:

    You need replace:

    esc_attr_e( $loop )

    By:

    echo esc_attr( $loop );

    Regards!

    Plugin Author yakacj

    (@yakacj)

    Hello @perikazo,

    _e and echo both are similar( _e generally used for string translate purpose), however here we don’t need to translate output so echo also ok ( as we escaped output ).

    • This reply was modified 9 months ago by yakacj. Reason: type mistake
    Thread Starter perikazo

    (@perikazo)

    Yes, it is similar, I know the wordpress code (I am a PHP developer) but if you use esc_attr_e it returns a text string sometimes and that is what produces the failure, and using echo esc_attr always returns numeric string in this case, in my website this produced a problem, the error is not the code of your plugin, it is that wordpress function that sometimes returns unexpected things, so to avoid errors, echo esc_attr is safer in this case. I hope it will help you for future updates.

    Thanks again for your great plugin ??

    Plugin Author yakacj

    (@yakacj)

    Glad to hear, that you also a developer! ????

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘Date and time field is not saved’ is closed to new replies.