We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 3633
    • 84 Posts
    Okay I have been working on these problems for too long, and need an answer pretty soon. If you click here you will see the problems which are circled. I am wanting to have the right month and year, not 1970 as the year and January as the month. Also I am wanting to know how to remove the information, which is circled in blue.

    Here is my code:
    [!Reflect?targetID=`55` &getDocuments=`1` &dittoSnippetParameters=`parents:55`!]
    [!Ditto?extenders=`dateFilter` &parents=`55`!]
      • 3633
      • 84 Posts
      Someone please tell me the answer I need to know - I need this done asap.
        • 28042 ☆ A M B ☆
        • 24,524 Posts
        Where is the date coming from originally? If it’s in the wrong format, or is part of an array, any invalid value such as that will cause the January 1 1970 output, since it’s expecting a UNIX timestamp.

        As far as the "information" section goes, that’s the default Ditto template. Make a new template for it and specify it in your Ditto snippet parameters.
          Studying MODX in the desert - http://sottwell.com
          Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
          Join the Slack Community - http://modx.org
          • 3633
          • 84 Posts
          Thanks for your reply, sottwell. I don’t understand about "make a new template for it and specify it in your Ditto snippet template". I haven’t had much experience with MODx, so I would appreciate it if you could please explain or show some code.

          This problem started when someone told me to edit default.templates.php - to delete
          (<span class="reflect_date">[+date+]</span>)
          because it didn’t want that to appear in the archive dates.