We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 21946
    • 283 Posts
    "If you don’t erase it manually it will not be erased."

    are you sure ? popup says me
    "Are you sure you want to change this template? Doing so will erase your current Template Variable values for this resource."

    It sounds like if values in database are going to be deleted forever. huh

    edit : i’m not talking about TVs but about their values stored in database
      [url=http://www.savepoint.fr/index.php?id=38] -petits tuyaux pour les d
      • 21946
      • 283 Posts
      Ok you’re right : values are not actually deleted from database grin
      It seems that you can switch back at anytime to your previous template and retrieve all your datas. Great !
        [url=http://www.savepoint.fr/index.php?id=38] -petits tuyaux pour les d
      • I did not test but it would have been a big problem if the TVs values were erased if you switch theme.

        Maybe the term "erase" in the prompt window is not adequate. They’re just not accessible if the new theme has not access to the concerned TVs.
          • 37099
          • 338 Posts
          Quote from: nyl at Jul 14, 2010, 10:06 AM

          TVs seems to be still tied to templates, like in modx evo. I’m not sure to understand why :
          - TV help you to build a custom form to create a specific content type (let’s say : news, event etc...) - data structure -
          - templates are just how you show datas on your site - data presentation -

          So yes, ofen you need to create a template for a specific content type, but not always

          ....
          isn’t that a little weird ? It will lead me to dupplicate templates if i want different content types to have the same presentation ?


          Not sure if i completely understand the problem or if this is a useful or sensible solution (and I’ve only done it in evo) but what I sometimes do is put the template code in a chunk, then I can include that chunk in different templates, I can then attach different TV’s to those templates but the chunk remains the same for all the templates.

          Mike
          • Quote from: thingstodo at Jul 15, 2010, 09:01 AM

            Not sure if i completely understand the problem or if this is a useful or sensible solution (and I’ve only done it in evo) but what I sometimes do is put the template code in a chunk, then I can include that chunk in different templates, I can then attach different TV’s to those templates but the chunk remains the same for all the templates.

            Mike


            You would still have to give your template access to the TV’s.
            The chunk is a presentation layer as well. You used it instead of putting your placeholders and TVs tags directly in your documents.
              • 21946
              • 283 Posts
              @thingstodo

              you’re right, with a chunk i could include a common template in two different templates...
                [url=http://www.savepoint.fr/index.php?id=38] -petits tuyaux pour les d
                • 37099
                • 338 Posts
                Quote from: nyl at Jul 15, 2010, 03:05 PM

                @thingstodo

                you’re right, with a chunk i could include a common template in two different templates...

                Glad to help smiley
                • Quote from: lossendae at Jul 14, 2010, 08:40 PM

                  I did not test but it would have been a big problem if the TVs values were erased if you switch theme.

                  Maybe the term "erase" in the prompt window is not adequate. They’re just not accessible if the new theme has not access to the concerned TVs.

                  Can you file an issue in JIRA for this? It’s clearly not clear. It just means that any values you had inputted without saving will be lost for that one Resource.
                    Ryan Thrash, MODX Co-Founder
                    Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
                    • 36541
                    • 222 Posts
                    Quote from: lossendae at Jul 15, 2010, 09:05 AM

                    You would still have to give your template access to the TV’s.

                    You don’t have to, actually. Any template can access any TV despite of it being binded or not to this template. What binding does is to allow to store a value for combination of TV and resource. If not binded, the *default* value is being used.

                    A short example to clarify. Say, a TV "window-title" exists with a default value of [tt][[+site_name]] &mdash [[+longtitle:ifemtpy=`pagetitle`]][/tt]. It can be accessed in any template and will return those fields. But when binded to a template, it’s value *can be set* for a resource, which uses the template.
                      This is the web: the only thing you know about who will come is that you don't know who will come.
                      • 27805
                      • 12 Posts
                      I don’t know about anyone else, but for me the greatest drawback of modx is the menu tree.

                      It’s great for managing everything BUT content. I am creatinging a real estate site in modx, but i’m looking at having to ask the client to scroll through 1000’s of properties without any method of sorting etc...not good. It will probably force me onto using wp3.0 as it has custom types and taxonomies (I don’t want to do this btw tongue ) Same goes for blogs. The only way to sort data in numbers that large is in tables. And it needs to be sortable and searchable. Access to chunks, templates, files etc is brilliant. Everything in one little sidebar. No complaints there. The other though is a gripe, and is really limiting the range of clients I can offer this amazing product too.

                      I know this functionality can be achieved using custom manager pages, but for a designer/front end developer like myself, the task is overwhelming. It’s not my area, so I wouldn’t even know where to start. Perhaps a working tutorial to demonstrate how to do it? The docss on manager pages are written for devs who know what their way around a mvc framework like no ones business, but for someone like me who can only use the system itself and develop some snippets and here and there, it’s not really feasible.

                      If there was some sort of way of administrating this action, it would be so so useful. I’ve mocked up a quick idea of what I’m talking about using a screenshot from batcher at the bottom. It’s in no way a complete idea, merely food for thought for you developers - but you’ll get the jist: