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

    I check instprocessor.php and see that it had information :

    htmlsnippet ---> description
    module ---> GUID

    If we do an install and choice update, does Modx execute this script and update database with this new information ?

    I ask this question because I do a delete/copy/paste of the new files, edit the snippet.jot.tpl and plugin.bottombuttonbar.tpl in the manager and I do not want to do an update via scipt if it is not necessary.

    Thank’s
      • 4018
      • 1,131 Posts
      Yeah, I updated the instprocessor.php file to update pretty much all information associated with snippets, plugins, modules, and templates when performing an upgrade. Now, there’s nothing to stop anyone from unchecking any given snippet, plugin, etc. to keep the installer from updating it. You always have a choice to not upgrade something and just upgrade it manually if you so choose. I felt that most people would want things like the description field updated since information about the version and such is usually included in these fields. About the only field I’m not sure of is the GUID field. Should this be targeted for updating during an upgrade? Or should it be left alone?

        Jeff Whitfield

        "I like my coffee hot and strong, like I like my women, hot and strong... with a spoon in them."
        • 26435
        • 1,193 Posts
        Quote from: Bravado at Nov 03, 2006, 08:53 AM

        Yeah, I updated the instprocessor.php file to update pretty much all information associated with snippets, plugins, modules, and templates when performing an upgrade.  Now, there’s nothing to stop anyone from unchecking any given snippet, plugin, etc. to keep the installer from updating it.  You always have a choice to not upgrade something and just upgrade it manually if you so choose.  I felt that most people would want things like the description field updated since information about the version and such is usually included in these fields.  About the only field I’m not sure of is the GUID field.  Should this be targeted for updating during an upgrade?  Or should it be left alone?

        If you overwrite the GUID won’t there be problems with plugins attached to modules by GUID.  I did this with an early version of MODx Resource Manager, and the G2 module and QuickEdit completely died.  The {PRE}.site_modules `guid` field should only be written to in initial install of a module. altering an existing globally unique ID can cause problems if I am not mistaken.

        -sD-
          Husband, Father, Brother, Son, Programmer, Atheist, Nurse, Friend, Lover, Fighter.
          All of the above... in no specific order.


          I send pointless little messages
          • 4018
          • 1,131 Posts
          Ok then...I’ll modify the instprocessor.php script to not upgrade any GUID fields. smiley
            Jeff Whitfield

            "I like my coffee hot and strong, like I like my women, hot and strong... with a spoon in them."
            • 22303 MODX Staff
            • 10,725 Posts
            Quote from: Bravado at Nov 04, 2006, 10:45 AM

            Ok then...I’ll modify the instprocessor.php script to not upgrade any GUID fields. smiley

            Hmmm, this is troublesome in my perspective, because if you upgrade a module, you need to make sure the GUID field from it matches the moduleguid field in a related plugin or snippet. So if you upgrade a module and it’s GUID changes, then any related plugins need to be updated as well, and if a plugin is updated by itself, well, then you need to see what the guid of it’s module is in the existing db. Needless to say, this is a mess at best, and without some serious coding to maintain these relationships properly, I don’t see any easy solution.