• Resolved mdp716

    (@mdp716)


    In the “Personalize your PDF” for the settings for a giving form’s PDF output I used the [date] tag because I need to output the current date in the PDF form.

    However, that outputs the date AND time (i.e., April 6, 2017 10:10am) and not just the date as I expected.

    Please correct this. The ideal would be to use two different tags:
    [date] = April 6, 2017
    [time] = 10:10am

    …which could then be used together for the full date and time, i.e., “[date] [time]” if both were needed.

Viewing 7 replies - 1 through 7 (of 7 total)
  • Hi!

    You can define the date format in the general settings : “Select a date and time format”

    You can just define like this : “j F Y” for “7 April 2017” return

    Thanks

    Plugin Author Florent Maillefaud

    (@florent73)

    Hi!

    Yes it’s correct like this.

    Thanks

    Thread Starter mdp716

    (@mdp716)

    I still maintain there is a bug.

    On the settings for a given form there are two entries for date format.

    The one which specifically references the [date] tag is set as follows:
    – – – Begin cut and paste – – –
    Use [date] in the name of your PDF
    Enter date format without space, -, /, _, etc..
    Fj,Y April7,2017
    – – – End Cut and Paste – – –

    Then further down is a section that reads as follows:
    – – – Begin cut and paste – – –
    Select a date and time format —> F j, Y g:i a —> April 7, 2017 9:24 am
    – – – End Cut and Paste – – –

    This second section DOES NOT reference the [date] tag.

    So what you are say is that the first setting is useless and has ZERO effect on the resulting form output despite the fact that it specifically says that it should whereas the second setting DOES have an effect on the resulting form output despite the fact that it completely omits any reference to the [date] tag.

    So that is, to me, a bug when you have a setting that does not do what it says it does and another setting does something that it does not say it does. Therefore, if that is how this should work then the first setting should be removed from the settings page and the second setting should be edited to show that it directly effects the inputted field on the resulting PDF document.

    I would, as mentioned elsewhere, also like to see a second edit window so that CSS style can be applied in what effectively would be placed in the <style></style> section of the head of a page. Inserting CSS styling inline with the HTML tags is a pain and results in messy looking code.

    Another thing I ran into is that I was using Dreamweaver to lay out my form’s PDF output and the editor for this plugin appears to see and treat word-wraps as carriage returns and effectively applies a “<br>” when one was not explicitly presented.

    Plugin Author Florent Maillefaud

    (@florent73)

    Hi!

    You can test me y form : https://restezconnectes.fr/form-de-test/

    – “Use [date] in the name of your PDF” is for the name of you PDF
    – “Select a date and time format” is for date tag actually j F Y G:i:s

    Here my code from my form :
    Defined j F Y G:i:s
    `<p style=”align:right:”>[date]</p>’

    I will test a dedicated CSS part.

    My plugin use wpautop() function : Changes double line-breaks in the text into HTML paragraphs (<p>…</p>).
    You can disable this with remove_filter( 'the_content', 'wpautop' ); in your functions.php file in your theme (for all website).

    Thanks

    Thanks

    Thread Starter mdp716

    (@mdp716)

    OK, I understand it now – the form for settings is not very clearly defined why there are two different settings for the date format.

    I still think it would be more functional if you had two separate settings, one for Date format and one for Time format and then simply allow a check box for whether to use either or both the date or time setting for the filename.

    Doing that allows for a lot more flexibility in the form creation. As one could select either [Date] OR [Time] or use both. Doing this would allow for the following:

    “On [Date] at [Time]…” OR you could use “At [Time] on [Date]…” OR you could use “Created: [Date] [Time]”

    I am highly resistant toward modifying the functions.php file for a single plug-in, page use, etc. so in this case I will just adjust to having to take out the carriage returns that were added when I cut and paste the HTML over to the form plug-in.

    Plugin Author Florent Maillefaud

    (@florent73)

    Hi!

    [time] is now available.

    And I’ve adding a option to desactivate line break auto.

    Thanks

    Thread Starter mdp716

    (@mdp716)

    Wonderful! Thank you I will check it out.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘[Date] Not Working Correctly ***BUG***’ is closed to new replies.