We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 29076
    • 615 Posts
    I tried with the snippet LastUpdate, but I could’nt get it to work. Can someone help me with this, please:

    I won’t to show a document’s last update-time in date and time. As easy as that.


    Thanks. smiley
      I think, thererfor I am! But what I am, and why...?
      • 6726
      • 7,075 Posts
      Never used it, but from its description LastUpdate "displays the last edited document", e.g the last time the website was upadted, not the last update for a given document.

      Maybe I didn’t understand fully what you intend to do, but you could use the editedon field in your Ditto template (don’t forget to add the dateExtender) or the plain template variable [tt][*editedon*][/tt] which you can format with FormatDate or better use PHx date modifier : [tt][*editedon:date=`%d.%m.%Y`*] [/tt]
        .: COO - Commerce Guys - Community Driven Innovation :.


        MODx est l'outil id
        • 29076
        • 615 Posts
        My mistake, I didn’t read the documentation good enough. I read $modx->documentObject[’variable-name’], and than i thought I had to make a snippet to make editedOn to work.

        But after reading your answer, I went back to the documentation, and I saw that it also could be used as simple as you said: [*editedon*].

        (For your information: It was the Last Edit for a given document.)

        Thanks. laugh
          I think, thererfor I am! But what I am, and why...?
          • 6726
          • 7,075 Posts
          You’re welcome smiley

          You’ll have to use PHx date modifier or a snippet to format the date though, otherwise you’ll just get the unix timestamp tongue
            .: COO - Commerce Guys - Community Driven Innovation :.


            MODx est l'outil id