We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 3866 ☆ A M B ☆
    • 350 Posts
    Hi there
    I have created a TV for images called {*TVphoto*} and have used the image widget and want to be able to assign appropriate alternative text to each image I upload. I created another TV called {*altText*} as a text template variable and put this into the alternative text box of the widget.
    So far so good, however, when the whole lot is parsed I get the image, the class I assigned but no alternative text, source only reads alt="" - what am I missing?
    I’ve tried trawling around for an answer but can’t find anything.
    I’m sure its a very simple answer but I’ve tried a variety of methods to no avail!
    I am using the {*TVphoto*} variable in a ditto call which is input as [+TVphoto+] which results in the image but no tag huh
      Helen Warner
      Number one pixel!
      Proud to be linked with MODX at Crimson Pixel
      • 25663 MODX Staff
      • 12,272 Posts
      Your syntax is wrong. It should be [*altText*] ... brackets, not braces.
        Ryan Thrash, MODX Co-Founder
        Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
        • 3866 ☆ A M B ☆
        • 350 Posts
        That was a typo error on the posting I have used [*altText*] in the "alternative text" section of the image widget and whilst when I look at the source code it shows the alt "" there is no text although I have entered the text on the documents with the template variable.

        I am using this as part of a ditto call - that is the [+TVphoto+] - and I assumed that the additional template variable I created [*altText*] would render but no joy so far.

        Any further suggestions - and I’ll check my typing next time embarrassed
          Helen Warner
          Number one pixel!
          Proud to be linked with MODX at Crimson Pixel