On March 26, 2019 we launched new MODX Forums. Please join us at the new MODX Community Forums.
Subscribe: RSS
  • for some reason in 0.9.5 beta 5 (1745) when this plugin is enabled, any changes I make to modules are not saved. The syntax highlighting is very nice!

    also, I changed line 25 from

      ta.parentNode.innerHTML+= '<iframe onload="setCode();" style="border:none; margin:0; padding:0; width:100%; height:400px;" id="codepress" [b]src="/assets/plugins/codepress/codepress.html"[/b]></iframe><br />';


      ta.parentNode.innerHTML+= '<iframe onload="setCode();" style="border:none; margin:0; padding:0; width:100%; height:400px;" id="codepress" [b]src="../assets/plugins/codepress/codepress.html"[/b]></iframe><br />';

    to make the relative path work in the manager.

    I also had to remove the <?php and ?> tags. I still can’t figure out the problem with saving. I will have to try to set some debugging output.

    thanks for bringing this to MODx

    Dr. Scotty Delicious, Scientist.
      Husband, Father, Brother, Son, Programmer, Atheist, Nurse, Friend, Lover, Fighter.
      All of the above... in no specific order.

      I send pointless little messages
    • I’ve installed this on; fixed the path problem (../blah instead of /blah, since it’s in a subdirectory). The line numbers are great, but the only color I get is everything between quote marks is blue. Even in a snippet with no comments at all. Any ideas?

      [edit] Figured it out... needs the <?php tags. So, since this is I just put the tags in comments:
        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
      • The French community is more advanced on the subject wink. Gildas has improve the plugin but it’s still a little buggy. There is investigation and he will post his work there.
        If you understand French go here
        • I think it’s best to point directly at Gildas’s code sadthought he wanted to check some things out first before posting it there tongue) No language skills is needed for code wink (that is, except for php)
            .: COO - Commerce Guys - Community Driven Innovation :.

            MODx est l&#39;outil id
          • Quote from: TobyL at Oct 18, 2006, 10:55 AM


            MODx is starting to freak me grin This is so cool man! Picked up a few typo’s in my snippet straight away...

            I did notice though that teh highlighting fails if there’s a lot of comments at the top of the snippet. I looked at several snippets and each time if it has lot’s of comments the code doesn’t highlight anymore. Come to think of it this may have to do with (single) quote’s in comments. The highlighter colors text in quotes, even in comments I noticed. Offcourse a single - single quote isn’t unusual in comments. Hmm,.. I’ll take that up with the developer I think.

            Just reporting back.. I did leave a message on fermads site and he replied:

            fermads :: 2006-10-19


            I think I know what you mean.
            Reserved words inside comments AND with single quote not closed with another single quote are being colored wrong. At least this is what I could reproduce from what you said.

            I’ll look into that in next CodePress version.
            • CodePress is the Best! It’s the best man!
                The fear of the Lord is the beginning of wisdom:
                MODx Co-Founder - Create and do more with less.
              • Wow!

                I can’t believe I missed this entire thread!

                Well, it appears that some duplicate efforts have been going on wink

                Anyway, I started this thread which illustrates an alternate approach at implementing EditArea into the core, so no Plugin.

                3 easy steps, and you’re done! ...No conflict with Saving, enabling Rich Text Editors, etc. All tested out very well.

                I may look at implementing a plugin for distribution-ease, but it sounded like garryn wasn’t too successful.

                Check out the thread, I’m enjoying EditArea very much!
                  Mike Reid - www.pixelchutes.com
                  MODx Ambassador / Contributor
                  [Module] MultiMedia Manager / [Module] SiteSearch / [Snippet] DocPassword / [Plugin] EditArea / We support FoxyCart
                  Where every pixel matters.
                • Great job ! Now I have to test it wink before making any new change to my custom version of the CodePress plugin...
                    Ackwa - Web Design & Development agency | Tours - France | Follow me on Twitter...
                  • Since the first release of this experimental plugin, CodePress has heavily improved and many bugs fixed. So you should go to http://codepress.fermads.net/ and download the latest version before testing it wink
                    • There’s a new version of the CodePress plugin attached. Should now work much better than the first one wink I’d be glad if some people will report their experiences so I can post it to the resources page, if it’s considered stable.