We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 4429
    • 429 Posts
    Hi Guys,

    Well, i’m at it again with another website see www.letstalkhorses.co.uk

    On the right-hand side I have three boxes. I want these to be editable and appear on every page (but contain the same content.

    I tired a basic template variable, but that allows the boxes to contain different content on each page. I want the same content in them on every page, but it needs to be editable as it change each month.

    Any ideas?

    Thanks
      • 4310
      • 2,310 Posts
      You could use three chunks, not as easy to edit for non tech users, but avoids the accidental editing of TV’s.
        • 4429
        • 429 Posts
        Once complete, i don’t plan on editing the site at all myself. It will be handed over to the magazine editor. So it really does need to be a simple process.

        I’m not experienced with TVs having never used them before so i’m unsure as to the best way to do this.
          • 4041
          • 788 Posts
          I think that system you have set up will work.
          If I remember correctly, when you edit the template variable default content itself and do not edit each documents content for that variable, they should all update accordingly with the default content.
            xforum
            http://frsbuilders.net (under construction) forum for evolution
            • 7231
            • 4,205 Posts
            Remember that you can use modx documents as chunks also with the @DOCUMENT binding in a TV. Or bypass the TV completely and use the GetField snippet directly in the template to build the sidebar and you can place the sidebar docs in an unpublished container (and keep the documents unpublished as well if you want).
              [font=Verdana]Shane Sponagle | [wiki] Snippet Call Anatomy | MODx Developer Blog | [nettuts] Working With a Content Management Framework: MODx

              Something is happening here, but you don't know what it is.
              Do you, Mr. Jones? - [bob dylan]
              • 4429
              • 429 Posts
              Well the content of those boxes will be Rich text and an image.

              Are you saying that it is possible to create the content in a new blankdocument and just have the TV call up document?

              is the call for that
              @DOCUMENT='doc id here'
              ?
                • 4310
                • 2,310 Posts
                @DOCUMENT 16

                Would do it, set the template to blank on the called document if you don’t want to add any html/css.
                  • 7231
                  • 4,205 Posts
                  Or use GetField and bypass the TV all together. wink
                    [font=Verdana]Shane Sponagle | [wiki] Snippet Call Anatomy | MODx Developer Blog | [nettuts] Working With a Content Management Framework: MODx

                    Something is happening here, but you don't know what it is.
                    Do you, Mr. Jones? - [bob dylan]
                    • 4429
                    • 429 Posts
                    I have a problem with just creating the template variables and pointing it at a particular document.

                    The issue is that for @DOCUMENT 16 to work, that particular document must use a blank template.

                    All is ok so far, but I need that document to be able to draw styles from my stylesheet. i.e The title, links and images etc.. all need to be positioned and styled correctly.

                    How can I achieve this?
                      • 7231
                      • 4,205 Posts
                      If the page where the document is being included into has the styles available then it should work no problem. The data will be included to the page’s content so it will fall under any code from the active document. It is like using include(), if it was an iFrame then it would need it’s own styling.
                        [font=Verdana]Shane Sponagle | [wiki] Snippet Call Anatomy | MODx Developer Blog | [nettuts] Working With a Content Management Framework: MODx

                        Something is happening here, but you don't know what it is.
                        Do you, Mr. Jones? - [bob dylan]