We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 34761
    • 11 Posts
    I’ve recently updated to MODx Revolution 2.1.2-pl (traditional) from MODx Revolution 2.0.7-pl (traditional) and a number of the output filters have stopped working.

    The best way for me to explain is show some examples to demonstrate what works and what doesn’t.

    Hopefully someone can at least reproduce this issue and at best help me fix it smiley

    I have a chunk called siteHeader, which has a load of html for building the html site header contents. The following code should produce a title output with a piece of text, prefixed with a page number if appropriate and default back to the pagetitle if there is no longtitle.
    <title>[[!getGet? &getName=`page`]][[+titleOverride:default=`[[*longtitle]]`]][[!If? &subject=`[[*longtitle]]` &operator=`isempty` &then=`[[*pagetitle]]` ]]</title>

    It actually returns blank. If I go onto a second page of pagination I get the following output:
    <title>Page 2 - </title>

    When it should be outputting :
    <title>Page 2 - Page Long Title Content</title>


    After finding this I started playing around. The pagetitle can be displayed fine in place of the longtitle without an issue, like so:
    <title>[[!getGet? &getName=`page`]][[+titleOverride:default=`[[*pagetitle]]`]]</title>


    The real thing that’s curious is that I can get the longtitle to appear if I put the following code in:
    <title>[[!getGet? &getName=`page`]][[+titleOverride:default=`[[*pagetitle]]`]][[!If? &subject=`[[*longtitle]]` &operator=`isempty` &then=`[[*pagetitle]]` ]]</title>
    <!--[[*longtitle]]-->


    By outputting the longtitle in a comment after (it even work before) the outputting of the same placeholder in the title html, it works.

    Can anyone offer any advice on this?

    Thanks in advance.
    David.

    Here’s all the relevant details from the ’System Info’:

    • MODx version: MODx Revolution 2.1.2-pl (traditional)
    • Server OS: CentOS release 5.6 (Final)
    • PHP version:5.3.6
    • MySQL Server version: 5.1.57
    • MySQL Client API version: 5.1.57
    • pdo_mysql installed: yes
    • no opcode caching
      • 22303 MODX Staff
      • 10,725 Posts
      This is due to http://bugs.modx.com/issues/5222 — a new release (2.1.3-pl) will be available with the fix shortly.
        • 34761
        • 11 Posts
        Thanks OpenGeek, good to know it’s not something we’ve done.

        I tried putting the fix in place from the 2.1.3pl bug fix in github (https://github.com/modxcms/revolution/commit/32fdbe0ce81efa67ebeb6cafe3d64f6b51d804f1) but it still didn’t work, any suggestions?

        It would be quite nice if I could fix it now and not worry about it and upgrade when the time comes.

        Thanks again,
        David.
          • 1343 ☆ A M B ☆
          • 2,213 Posts
          They have released 2.1.3, could you try upgrading the entire install first? There could be other affected files.
            Patrick | Server Wrangler
            About Me: Website | Tweets |  MODX Hosting
            • 35662
            • 12 Posts
            I’m having the same sort of problems using

            [[+titleOverride:default=`[[*longtitle]]`]]

            and I’m running the latest version of Modx Revolution (2.1.3)? Bit weird, a fix or a work around for this would be very handy! smiley
              • 22303 MODX Staff
              • 10,725 Posts
              Quote from: osquarino at Jul 27, 2011, 09:16 AM

              I’m having the same sort of problems using

              [[+titleOverride:default=`[[*longtitle]]`]]

              and I’m running the latest version of Modx Revolution (2.1.3)? Bit weird, a fix or a work around for this would be very handy! smiley
              This example works perfectly for me in MODX 2.1.3-pl when the titleOverride placeholder is empty, returning the value of longtitle as expected. What problem are you having with it?