We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 22830
    • 4 Posts
    Hi,
    for the last couple of days I’ve been trying to add my site’s Wordpress blog to Modx Revo with no success. I’ve tried probably a dozen different ways such as using php includes, curl includes, adding a php bridge file, including relatively from blog folder, rewriteUrls, etc. but they have all failed. Does anyone know how to properly integrate wordpress into modx, specifically into modx revolution rc1? I just want to be able to add my header and footer chunks. Any help would be much obliged, thanks.
      • 26016
      • 561 Posts
      These are my 2 fave systems. But I would never try to mix them. IMHO, they’re just too big and different from each other. I’ve had clients who wanted this type of Frankensteining with other non-MODx systems, and in my experience it has always been a total cluster$%^$%^. An excellent PHP coder might be able to pull it off... that’s not me. It’s tempting to try it when you have 2 systems with non-overlapping features. I suggest you resist that temptation.

      Instead, if I were doing this, I would start with Wordpress, and get that looking good. Then, because MODx is easier to template, I would make a simple template that used the header and footer of the Wordpress theme. Finally, I would make links to the MODx site from WP. Jury-rigged, to be sure. smiley You could also do the opposite. I’ve templated both quite a lot, and though theming WP is not hard, MODx is even easier.

      You’ve been warned. Maybe someone else will have another idea.

        MODx and Wordpress development
        Linux, PHP 5.2, MySQL 5.0, Evo 1.05, Revo 2.08-pl, Firefox 4
        • 18913
        • 654 Posts
        Search for a thread called "Running Wordpress functions in MODx". I’m sure about the wisdom on editting the MODx index.php file that I wrote about there. So I probably wouldn’t do that...
        MattC
          • 22303 MODX Staff
          • 10,725 Posts
          Quote from: mconsidine at Apr 01, 2010, 06:46 PM

          Search for a thread called "Running Wordpress functions in MODx". I’m sure about the wisdom on editting the MODx index.php file that I wrote about there. So I probably wouldn’t do that...
          MattC
          FWIW, doing this will burden every request to your MODx site with the overhead of the Wordpress integration. IOW, it won’t help performance any, for sure. The same would be true including MODx functions in WordPress. Even the best of PHP developers would have to hack at least one of the systems to make any kind of decent integration, and it would take a lot of work; unfortunately, different PHP applications have different architectures, and they are not meant to be welded together like this.
            • 22295
            • 153 Posts
            As a simple workaround, you could always do it client-side ajax...
            $(’wpContainer’).load(’/wp/page.html’);
              • 18913
              • 654 Posts
              FWIW, doing this will burden every request to your MODx site with the overhead of the Wordpress integration. IOW, it won’t help performance any, for sure. The same would be true including MODx functions in WordPress. Even the best of PHP developers would have to hack at least one of the systems to make any kind of decent integration, and it would take a lot of work; unfortunately, different PHP applications have different architectures, and they are not meant to be welded together like this.

              Thanks for that perspective OpenGeek. I was pretty sure there was a good technical reason not to take that approach, but didn’t know what it would be. Or, rather, couldn’t articulate specific technical reasons very well. And since I’m certainly not even close to being one of "the best of PHP developers" I’ll side with your advice.

              BTW, my experience has only been with MODx Evo.

              MattC
                • 22830
                • 4 Posts
                Well it looks like I should just leave them alone then. Its unfortunate but I should’ve realized it would be harder than I thought to integrate these two different systems together. Thanks for all the advice!
                  • 25663 MODX Staff
                  • 12,272 Posts
                  Out of curiosity, are you wanting to integrate because you have an existing WP blog or because you just want to use WP?
                    Ryan Thrash, MODX Co-Founder
                    Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
                    • 22830
                    • 4 Posts
                    I find Wordpress to be great for blogs but not a good cms while MODx seems to be a great cms due to its flexibility but it’s missing its own adequate blog feature so I had the stupid idea that I could just combine both. To be honest I haven’t tried MODx’s blog feature but I imagine it’s not up to par. In any case I had already skinned my Wordpress blog to look like the rest of my site (which for me is a big pain) so I didn’t necessarily want to scrap it; besides the fact that the Wordpress blog theme I’m using looks fantastic heh.
                      • 25663 MODX Staff
                      • 12,272 Posts
                      What features do you need in a blog ... basic blogging/commenting/etc. or the other bits like trackbacks/pingbacks? If the former, what made you assume MODx was not up to par?
                        Ryan Thrash, MODX Co-Founder
                        Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me