We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 19298
    • 76 Posts
    MichaelHarringtonDesigns Reply #1, 15 years, 8 months ago
    Hi everyone

    I have added this line into the template on my Modx Rev site

    1)<meta name="description" content="[[*description]]">

    2)I have then created a TV with the name description, input type: text and ticked which templates to use it on..

    3) On the home page I go to Document "Home" and in Template Variables section add the text into the TV "description"

    4)The problem is when I view source I get this!!

    <meta name="description" content="Array">

    Why does "Array" appear and not the text I have entered in part 3,, does anyone know what I am doing wrong? I have missed something easy just cannot see it at the moment..

      • 3749
      • 24,544 Posts
      The description field is not a TV. It’s a regular resource field that appears near the beginning of the Create/Edit Resource form in the Manager. I’m going to guess that you haven’t been filling it in. wink

      You can use a TV for the meta statement if you want to, but you’ll have to give the TV a different name.
        Did I help you? Buy me a beer
        Get my Book: MODX:The Official Guide
        MODX info for everyone: http://bobsguides.com/modx.html
        My MODX Extras
        Bob's Guides is now hosted at A2 MODX Hosting
        • 19298
        • 76 Posts
        MichaelHarringtonDesigns Reply #3, 15 years, 8 months ago
        OK it works now thanks Bob, laugh I changed the name of the TV.

        I have a better understanding of TV now..
          • 3749
          • 24,544 Posts
          Quote from: MichaelHarringtonDesigns at Feb 26, 2011, 05:24 PM

          OK it works now thanks Bob, laugh I changed the name of the TV.

          I have a better understanding of TV now..

          Glad I could help smiley

          It’s confusing because some people (and some older docs) refer to the resource fields as TVs though they’re really two different animals. BTW, if you use the ’description’ resource field instead of a TV, your pages will load a little faster because, unlike resource fields, TVs are stored in a different table and MODx needs to retrieve and render them separately. The description field also shows up on the Create/Edit Resource main page without the user having to click on the TV tab and wait for it to come up, so editing resources in the Manager will be faster too. OTOH, using the TV allows you to use @INHERIT.
            Did I help you? Buy me a beer
            Get my Book: MODX:The Official Guide
            MODX info for everyone: http://bobsguides.com/modx.html
            My MODX Extras
            Bob's Guides is now hosted at A2 MODX Hosting