• Resolved umairzept

    (@umairzept)


    I am using mla gallery plguin in a wordpress site. I am trying to get pdf files as follows

    [mla_gallery]
    date_query = array(array( ‘after’ =>’1 year ago’,’before’ => ‘today’ ))
    post_parent=all post_mime_type=application/pdf mla_debug=true
    [/mla_gallery]
    As you can see I want to fetch all those pdf files that were added in Media last year. Eventually I will change it to get value of dates like before 2020-05-18 and after 2020-05-01 (18th May 2020) format but I am getting error

    ERROR: Invalid mla_gallery date_query = ‘false’

    I have set Php reporting 0x7FFF and MLA Reporting to 128 but only get the above error and nothing else. How do I fix this error?

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter umairzept

    (@umairzept)

    adding correct date_query parameters solved the issue for me. I was missing inverted commas

    Plugin Author David Lingren

    (@dglingren)

    Thanks for your question and for digging in to solve the problem yourself.

    MLA uses a PHP function to evaluate taxonomy, meta and date queries. The error information returned from the PHP function is very limited and thus the message you see isn’t very helpful. As you discovered, careful inspection of the query parameter is the best solution. Copying and pasting queries from support forum topics is tricky because the source often includes “smart quotes” and other formatting characters.

    Thanks again for finding your own solution and for your interest in the plugin.

Viewing 2 replies - 1 through 2 (of 2 total)

The topic ‘ERROR: Invalid mla gallery date_query = ‘false’’ is closed to new replies.