We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 33673
    • 14 Posts
    I have made some template veriables I use for different stuff in my template. But however I don’t want the publishers and content editors to be able to use these. And I don’t want the TV’s to be visible when you edit content under the "Template Variables" list. So is it possible to hide certain TV’s from showing up depending on what user is logged in?


    Also the FlexSearchForm doesn’t seem to be able to search for foreign characters, is there a fix for this yet? Tried some spanish guys fix but couldn’t get it to work.

    Thanks.
      • 3270
      • 7 Posts
      I am interested in a way to do this as well. Some template variables are used only for the administrators and not for the content editors. Does anyone have a solution to this?

      Thanks,

      Ben
        • 27376
        • 576 Posts
        Create a manager document group (in Security tab) and assign your template variable to the group. Then only users in the group will be able to see those template variables.

        A little known fact about the the Permissions system is that it also applies to the template variables, not just the documents.
          • 3270
          • 7 Posts
          Exactly what I was looking for. Thank you.

          Ben
            • 3270
            • 7 Posts
            This solution worked perfectly for hiding template variables for certain users.

            Is it possible to do the same thing for different documents? I want to show a template variable on only one document. I tried putting that document into a group and then assigning that template variable to the group but it did not seem to work. The template variable became invisible to all users except the admin. Then I tried assigning a new user group to the document group i created and adding all of the users to that group, but the template variable still showed up on all documents.

            Thanks,

            Ben
              • 27376
              • 576 Posts
              Quote from: bglassman at May 05, 2007, 12:31 PM

              Is it possible to do the same thing for different documents? I want to show a template variable on only one document.

              Ben
              You’re thinking of something more along the lines of Document Variables, which MODx doesn’t do. One thing you can try is to create a new template, name it something like "DocID x" (for organizational purposes) and then assign a single document that template. Once that’s done, you can then assign any number of TVs to that template and they will only show up for the document you assigned the template to.

              Of course, this is kind of against the philosophy of TVs, but MODx is really whatever you make it smiley

              Completely ignoring the topic title, consider this thread for a good example on how to use TVs:
              Something like "document variables" instead of TV