Current Date - Conditional Rules

  • Profile Image
    spartan02
    Asked on October 09, 2013 at 05:45 PM

    Hi,

     

    Is there a way to pull in the current day of the week into the form automatically? I am trying to use the "conditions wizard" to customize my form depending on the day of the week, but unfortunately I cannot proceed because I don't know of any way to pull in the current day of the week.  Does anyone have any thoughts/suggestions?  Any help you could provide would be great.

     

    Thank you.

  • Profile Image
    Cesar
    Answered on October 09, 2013 at 07:04 PM

    Hello, 

    Kindly refer to this thread: http://www.jotform.com/answers/225356-Using-DateTime-field-with-Conditional-Logic-based-on-current-date

    If you do need further assitance, do let us know thank you.

  • Profile Image
    spartan02
    Answered on October 09, 2013 at 08:32 PM

    Hi,

     

    Thank you.  The link was helpful. I had one follow up question.  My goal is to have it such that I can use the datetime field to create conditional rules based on the days of the week.  For example, since today is Wednesday, I would use the datetime field and create certain rules such that only certain fields within my form appear.  The rest would be hidden.  

    Based on what I read, it looks like the datetime field needs to be inserted into the form inorder to use any conditional rules based on date correct? If so, is there is a way to make it such that the datetime field just shows the current date and remains invisible so that users do not try to alter the date?

    Thank you!

  • Profile Image
    jeanettebmz
    Answered on October 09, 2013 at 09:48 PM

    Yes, that is possible, simply inject a custom CSS to hide the DateTime field

    For example on this form

    I've hidden the dateTime field with these codes

    #label_25.form-label-top, #id_25.form-line #cid_25.form-input-wide{
    display:none;
    }

    To find out the fields ID's of your own form, please check this guide

    How to find Field IDs & Names

    Check also this one, to know  how to inject custom CSS

     

    If you need further assistance, let us know

  • Profile Image
    spartan02
    Answered on October 13, 2013 at 07:57 PM

    Thank you!

  • Profile Image
    ashwin_d
    Answered on October 13, 2013 at 10:09 PM

    Hello spartan02,

    You are welcome.

    Do get back to us if you have any questions.

    Thank you!