We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 22548
    • 58 Posts
    Hi everybody!
    I have just read that the summary placeholder is superseded by [+introtext+] and will not be natively supported anymore, thus it might be deprecated with any next version of Ditto. sad

    I’m just figuring out how Ditto works and think that [+summary+] actually is very helpful, as it helps me to get full control over the output. I suppose it might be possible to define a class for introtext in my css as well (at least I hope so), but how would I place a picture into the introtext? I guess what I would need then is a RTE inside my introtext field. But even if such a thing would be possible, it would probably not make Ditto less resource intensive...

    Anyway, does anybody know how to get full control over the introtext field (including how to insert pictures)?
    Greetings, Alex
      • 25663 MODX Staff
      • 12,272 Posts
      Hi Alex,

      You’d have to hack the manager files. Why not just use a TV + a widget?
        Ryan Thrash, MODX Co-Founder
        Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
        • 22548
        • 58 Posts
        Wow, thanks for the quick answer, rthrash! laugh
        Well, at the moment I’m just fine with how things are, as summary is still supported. I’m just wondering if this could be stopped soon, as I am looking for a longterm CMS/CMF companion and just NEED to display a list with thumb pictures and short introtexts. But if you say that can be done otherwise as well I’m happy already and will have to figure out how that works.
        Thanks again and greetings to you, Alex
          • 18397
          • 3,250 Posts
          The [+summary+] placeholder itself will be supported via extender for some time. [+introtext+] has not superseeded it per se, its just less resourse intensive since Ditto does not need to calculate its value. You can have an RTE in the introtext field thanks to a plugin written by xwisdom (not in repository, search the forums).
            • 22548
            • 58 Posts
            Quote from: Mark at Jul 16, 2007, 08:35 AM

            The [+summary+] placeholder itself will be supported via extender for some time. [+introtext+] has not superseeded it per se, its just less resourse intensive since Ditto does not need to calculate its value.
            I understand, that’s good to hear and thanks for the explanation!
            You can have an RTE in the introtext field thanks to a plugin written by xwisdom (not in repository, search the forums).
            That would be great! grin (Especially as I have just understood that [+summary+] doesn’t translate into the summary class (css) or deliver pictures in the blog overview, but only in the blog entry page. In the overview page it translates into text only in my template’s regular css.) I don’t know if there is a solution for this with phx, as I didn’t yet grasp all the things possible with Ditto, but it seems to me that this plugin would be exactly what I need. I’ll look for it!
            All the best to you, Alex

            ............................................
            edit: Couldn’t find the plugin yet, but I found this message
            http://modxcms.com/forums/index.php/topic,15634.msg100700.html#msg100700
            saying you could get an RTE for the summary using NewsEditor. Not sure if I should use that instead of Ditto, actually I don’t want to write blogs but just need a tool that can display a list of summary/preview texts with pictures...
              • 22548
              • 58 Posts
              O.k., I guess I found something, although it seems to be for a snippet called NewsListing:
              http://modxcms.com/forums/index.php/topic,864.msg5546.html#msg5546
              1) Create called RichText News Summary
              2) Add the following code inside the code area of the plugin:
              global $replace_richtexteditor;
              $replace_richtexteditor[] = "introtext";

              3) Attach the plugin to the OnDocFormRender event
              4) Save the plugin

              That’s it you’re done!

              Note: The FCKEditor does not auto size the RichText box to match the width and height of the original texbox. This means that the RichText Summary will have a height of 400px by default but you can however and code to the plugin to rectify this problem. Use the $modx->event->output() function to output text to the browser.

              Disclaimer: The above provides an easy way to "hack" into the system without touching core code. Future versions of the manager might break this hack.

              Now it would be great if this works (or even lasts for 0.9.7), but I can`t find the OnDocFormRender event or any other event in the Ditto documentation page or in myfriendscallmebill’s 2.0.1 documentation. I also had a look at snippet.ditto.php, but I guess it’s not in Ditto, but in some other core files... huh

              Does anybody know how to do this? Thanks for all your help already, frankly I’m not used to getting so much help in a forum as I have already gotten here and on modxcms.de!
                • 18397
                • 3,250 Posts
                xWisdom’s work is a MODx plugin which you can install by choosing Resources->Manage Resources->Plugins. From there you should be able to copy and paste the code and attach the event.

                P.S. NewsListing was Ditto’s predecessor.
                  • 22548
                  • 58 Posts
                  Oh, wow, that worked! laugh Jippie!
                  I thought I had to look for another plugin, but that was it already. I was a little confused, it seems...

                  Thank you so much, this makes life much easier for me! laugh