Forminator Pro customization.

Is there any way to allow the visitor to only pick dates in the Future and from the past.

  • Mhamdi Youssef
    • Flash Drive

    Hello David

    I hope you are doing well today!

    I double checked Forminator forms' setting to see if there is such functionality, but unfortunately, there is no such functionality in Forminator. However, there is a simple similar to what you want, we have a section on Datepickers' settings that allows you to restrict/exclude some days or a range of days from the date picker calendar.
    Screenshot:

    You can set it to restrict days or range of days or even restrict days in a week like (Friday, Monday), Also in the same section you can choose a range of years, for instance, you can set it to 1900-2000 so that the visitor will be choosing days only between that range of year :slight_smile:

    However, the functionality that you asked about it is really interesting so I will task it to Feature Requests so that our developers can take a look at it and hopefully they add it in future requests.

    Please keep an eye on this thread so that if I get an update I will replay to you here, also you can check plugin Roadmap :slight_smile: link: Roadmap

    I hope this helps!

    Best regards,
    Youssef

  • David
    • The Incredible Code Injector

    Thank you, yes a simple toggle switch is all that is needed to say "From Today forward" or "from current date onward" or such.

    Whilst interesting the way youve pointed out doesnt really help other than restricting how far back they can go.

    Thank you

    DJ

  • David
    • The Incredible Code Injector

    Another issue I've just noticed is that the initial form date layout is incorrect even though it's set correctly in the form settings, please see attached. Can this be fixed?

    it should be as per British Norm - Day Month Year

  • Mhamdi Youssef
    • Flash Drive

    Hello David

    I hope you are doing well today!

    I forwarded your interesting idea about the future/past to our plugin devs and they told me that they already have this in their schedule of improvements.
    Also, they gave me a file contains some optimizations that can help you to work with this functionality and also to fix the D/M/Y format issue without the need to wait for the next updates :wink:

    Here is the file: Forminator-opt-ad.php.

    To be able to use the file with all the updates please follow these steps:
    --> Add the file to Mu-plugins folder on your site, to do this:
    -----> Access to your site using SFTP/FTP, Go to /site/public_html/wp-content/mu-plugins/
    -----> Past Forminator-opt-ad.php file in there

    --> Go to Forminator > Edit your form > Edit your datepicker field > Styling -> Additional CSS Classes.

    Please Note: if you need to use your datepicker as "From Today forward" or as "From Today backward" you need to add a class in the Additional CSS Classes field in your datepicker.

    --> For "From Today forward" option add this class: wpmudev-future-time
    --> For "From Today backward" option add this class: wpmudev-past-time

    After doing this check your form and see the results.

    Please Note: in future updates you won't need to add classes to your datepickers field.

    Please if you need further help for this, please feel free to replay here.

    I hope this helps, Have a nice day!

    Best regards,
    Youssef

  • Mhamdi Youssef
    • Flash Drive

    Hey David

    Please if you couldn't add that file in the last replay or you are afraid of something, don't hesitate to ask me :slight_smile: I will be happy to help you out.

    Could you please provide me with the FTP/SFTP/cPanel also WP-admin credentials of your site, so that I can add the file to your site.

    Please, DO NOT post any credentials here, as it's a public forum. You can send us your details through our contact form https://premium.wpmudev.org/contact/#i-have-a-different-question using this template:

    Subject: "Attn: Mhamdi Youssef"
    -WordPress admin username
    -WordPress admin password
    -login URL

    -FTP credentials (host/username/password)
    or
    - cPanel credentials (login URL/username/password)

    -link back to this thread for reference
    -any other relevant URLs

    Please use this subject line to ensure that it gets assigned to me.

    Cheers,
    Youssef

Thank NAME, for their help.

Let NAME know exactly why they deserved these points.

Gift a custom amount of points.