We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 4095
    • 372 Posts
    Just a tip for anyone wanting to display MODx tags in an HTML page. I’ll use [*content*] as an example

    The problem:

    If you just type [*content*] it will be parsed by MODx, regardless if its in a CSS <pre> or <code> tag and output the result.

    The Display Snippet outputs the content of a snippet, where as I just wanted the tag syntax.

    The soloution:

    Therefore you can use [&lowast;content&lowast;] but it doesn’t copy and paste well

    Or you can use [<!-- -->*content*<!-- -->] which works and can be copied and pasted.

    Big thanks to OpenGeek and Vbrilon for solving it for me smiley
      [img]http://www.emanz.ac.nz/assets/images/logo/emanz-icon_16x16.gif[/img] Emergency Management Academy of New Zealand [br] http://www.emanz.ac.nz[br][br]MODx Sandbox Login: sandbox Password: castle [br]
      Admin Sandbox Login: sandbox Password: castle
      • 33337
      • 3,975 Posts
      Great TIP!!

      Thanks for sharing.

      regards,

      zi
        Zaigham R - MODX Professional | Skype | Email | Twitter

        Digging the interwebs for #MODX gems and bringing it to you. modx.link
        • 15914
        • 145 Posts
        Thanks for that!

        Will become handy when I’m writing up some of my own online MODx Documentation (if I ever get around to it).
          Kunal Kapoor
          Technical Director
          Limesharp Internet Limited - Effective, Functional, Standards Compliant

          IRC Nick: KingKoopa
          Skype ID: KingKoopa16
          • 28042 ☆ A M B ☆
          • 24,524 Posts
          That’s a safer method that using html entities in FCKEdit; it is very rude about converting your nice safe entities back into tags!
            Studying MODX in the desert - http://sottwell.com
            Tips and Tricks from the MODX Forums and Slack Channels - http://modxcookbook.com
            Join the Slack Community - http://modx.org
            • 6726
            • 7,075 Posts
            Great tip indeed !

            Nice to know grin
              .: COO - Commerce Guys - Community Driven Innovation :.


              MODx est l&#39;outil id
              • 32241
              • 1,495 Posts
              Nice useful tips.

              Added to repository.
                Wendy Novianto
                [font=Verdana]PT DJAMOER Technology Media
                [font=Verdana]Xituz Media
                • 4273
                • 356 Posts
                If you just type [*content*] it will be parsed by MODx

                what do you mean by "parsed by MODx" ?

                I use [*content*] and have not noticed anything unusual
                  SMF Bookmark Mod - check it out
                  http://mods.simplemachines.org/index.php?mod=350
                  • 25663 MODX Staff
                  • 12,272 Posts
                  Are you using Safari still bugsmi0? RTEs don’t work in Safari which is why it’s working for you (rich text editors like FCK and Tiny MCE). What they’re referring to is physically ouptuting "[*content*]" to the browser verbatim without it being turned into the actual content of the page.
                    Ryan Thrash, MODX Co-Founder
                    Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
                    • 28373
                    • 204 Posts
                    Quote from: Briggsy at Mar 02, 2006, 12:40 AM

                    Just a tip for anyone wanting to display MODx tags in an HTML page. I’ll use [*content*] as an example

                    The problem:

                    If you just type [*content*] it will be parsed by MODx, regardless if its in a CSS <pre> or <code> tag and output the result.

                    The Display Snippet outputs the content of a snippet, where as I just wanted the tag syntax.

                    The soloution:

                    Therefore you can use [&lowast;content&lowast;] but it doesn’t copy and paste well

                    Or you can use [<!-- -->*content*<!-- -->] which works and can be copied and pasted.

                    Big thanks to OpenGeek and Vbrilon for solving it for me smiley

                    thanks!, this explains the problem I was having I thought it was kinda odd <pre> didn’t work - now I can stop using jpeg’s for code examples smiley
                      • 4273
                      • 356 Posts
                      Quote from: rthrash at Mar 24, 2006, 12:18 PM

                      Are you using Safari still bugsmi0? RTEs don’t work in Safari which is why it’s working for you (rich text editors like FCK and Tiny MCE). What they’re referring to is physically ouptuting "[*content*]" to the browser verbatim without it being turned into the actual content of the page.

                      Yes using Safari the world’s #1 rocking browser he he, but lately been using camino for editing purposes, i’ve tested the site in safari, camino, firefox and nothing unusual using [*content*]

                      when you say physically outputting you mean typing just [*content*] ? I have uses only that and it works in the browser i mentioned, what browser does it get messed up in ?
                        SMF Bookmark Mod - check it out
                        http://mods.simplemachines.org/index.php?mod=350