We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 21257 MODX Staff
    • 730 Posts
    Hi all,

    I created a mm widget yesterday which displays some additional information for TVs whose current value is @INHERIT.
    It will show what the inherited value is, if any, and what doc it came from.
    Currently, it works well for plaintext and dropdown TVs. I’m planning to get it working for image TVs next, then I’ll check out other TV types.
    Create a subdir called showinherited under the widgets directory, and put the attached file showinherited.php there.

    Call it like this in your mm rules:
    mm_widget_showinherited('tvPageHeaderText,tvSidebarVersion,tvSidebarEvents', '', '2', '4');
    


    note: the second parameter doesn’t do anything at the moment.

    Release early and agitate, right? tongue
      Mike Schell
      Lead Developer, MODX Cloud
      Email: [email protected]
      GitHub: https://github.com/netProphET/
      Twitter: @mkschell
      • 34017
      • 898 Posts
      that’s a slick addition. thanks.
        Chuck the Trukk
        ProWebscape.com :: Nashville-WebDesign.com
        - - - - - - - -
        What are TV's? Here's some info below.
        http://modxcms.com/forums/index.php/topic,21081.msg159009.html#msg1590091
        http://modxcms.com/forums/index.php/topic,14957.msg97008.html#msg97008
        • 7231
        • 4,205 Posts
        This is cool. I did not know that you could do widgets for MM, how cool is this grin
          [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]
          • 25663 MODX Staff
          • 12,272 Posts
          Mike did you ever complete this widget? Now would be a great time to polish it up. wink
            Ryan Thrash, MODX Co-Founder
            Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
            • 10313
            • 375 Posts
            Does this work with evolution (1.0.2)?

            I only receive a popup-message reading
            ManagerManager: An error has occurred: TypeError - $("#tvgroessenklasse") is null

            The [tt]mm_rule[/tt] is
            mm_widget_showinherited('tvgroessenklasse', '', '', '8');


            The template has a TV (dropdown) called "groessenklasse". The [tt]select[/tt] in the DOM has the ID ’tv18’, and not ’tvgroessenklasse’ as I had expected according to that error message. Even when I change the mm_rule with ’tv18’, I only get the popup-message (now reading ... ’#tv18’ ...).