Date / Time fields

Home Forums Quform PHP Date / Time fields

This topic is: not resolved
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #32188
    Juan1973
    Participant

    I tried to follow the documentation to add date and time selectors, but it’s not correct. I take here the Date example, but it’s the same with Time.

    First, in “Adding a Date form element” you can read “There is an example of the Date element HTML in the file example-all-elements.html”. But that file doesn’t exist, at least in the version I bought today in Envato. Anyway, I created this html element in my form:

    <div class=”quform-spacer”>
    <div class=”quform-input”>
    <input id=”date” type=”date” name=”date”>
    </div>
    </div>

    I followed the rest of the steps, and the form worked fine before. But now I get this error:

    “Element ‘date[month]’ does not exist in the HTML but failed validation, you must either add the HTML for this element into the form or remove the element configuration from the process file.”

    This is the code in “process.php”:

    $date = new Quform_Element_Date(‘date’, ‘date’);
    $date->addValidators(array(‘date’));
    $form->addElement($date);

    Obviously, if I remove this configuration I get the “Sent” message, but I don’t receive that data in my email.

    #32193
    Ally
    Support Staff

    You don't have permission to view this content. Please log in or register and then verify your purchases to gain access.

Viewing 2 posts - 1 through 2 (of 2 total)
  • You must be logged in to reply to this topic.
Be inspired. © 2020 ThemeCatcher Ltd. 20-22 Wenlock Road, London, England, N1 7GU | Company No. 08120384 | Built with React | Privacy Policy