On March 26, 2019 we launched new MODX Forums. Please join us at the new MODX Community Forums.
Subscribe: RSS
  • So, I’ve taken up playing with xml-rpc to see if I can make it work with external applications such as Scribefire. I have downloaded but had no luck with http://modxcms.com/forums/index.php/topic,5827.msg42532.html#msg42532.

    After looking at it for a while it seems to me that we could make this easier by either building it as a snippet and including it in a document in modx and then accessing the appropriate functions vs. connecting as an external xmlrpc.php file for this.

    It would seem that a single file xmlrpc would be best instead of a snippet plus a snippet call but I’m looking at trying to be modx-y about this.

    Possible reason’s to have it as a snippet would be to enable bloggers to put the snippet calling document under the blog parent document and therefore be able to have multiple blogs on the same server with different authors and different logins.

    On the flip side is there a way to get access to the modx document parser class from a script along side a modx install without installing the MODx API and not opening up the site to security issues?

    So, any thoughts on this would be appreciated as I build the modx blog kit.

    Cheers,

    Jay
      Author of zero books. Formerly of many strange things. Pairs well with meats. Conversations are magical experiences. He's dangerous around code but a markup magician. BlogTwitterLinkedInGitHub
    • Quote from: smashingred at Sep 21, 2008, 02:41 PM

      After looking at it for a while it seems to me that we could make this easier by either building it as a snippet and including it in a document in modx and then accessing the appropriate functions vs. connecting as an external xmlrpc.php file for this.

      It would seem that a single file xmlrpc would be best instead of a snippet plus a snippet call but I’m looking at trying to be modx-y about this.
      XML-RPC (and JSON-RPC) are already integrated into Revolution. I suggest looking at the libraries there for inspiration (core/model/modx/xmlrpc/ and core/model/modx/jsonrpc/), but creating a snippet is absolutely the best way to integrate this into 0.9.6.x. A MODx Document should serve as an XML-RPC server IMHO. In Revolution, there will be custom mechanisms for easily creating custom RPC server Response classes (in Revolution there is a class representing a Request and a Response), and extending them to be as simple or complex as you need. But in 0.9.6.x, you’ll need to do all the heavy lifting in a snippet (and/or possibly a plugin).

      Quote from: smashingred at Sep 21, 2008, 02:41 PM

      On the flip side is there a way to get access to the modx document parser class from a script along side a modx install without installing the MODx API and not opening up the site to security issues?
      You can do such things in 0.9.6.x, but many things simply will not work as intended and the code to do it can be a bit painful to write. This was another of the major shortcomings which the Revolution design was intended to solve.
      • Jason, I thought the quickest way to the finish line would be a snippet and a document as the server location. This would give full access to the api and offer control as I could use parameters for settings like blog folder and such.

        The goal is to allow the blogger, movable type, MetaWeblog api and maybe a couple of others for maximum of compatibility with blog editing apps and clients.

        This would also allow integration of the trackbacks and pings that would currently use the IXR Class I’ll look at the modx XMLRPC class and see how that is worked.

        Cheers and thanks,

        Jay
          Author of zero books. Formerly of many strange things. Pairs well with meats. Conversations are magical experiences. He's dangerous around code but a markup magician. BlogTwitterLinkedInGitHub
        • Quote from: smashingred at Sep 21, 2008, 07:59 PM

          The goal is to allow the blogger, movable type, MetaWeblog api and maybe a couple of others for maximum of compatibility with blog editing apps and clients.

          This would also allow integration of the trackbacks and pings that would currently use the IXR Class I’ll look at the modx XMLRPC class and see how that is worked.
          I’ll try and dig up some sample servers I wrote tomorrow. Though they had nothing to do with Blogging API’s, trackbacks, or pings, it will at least be a good example of using the implementation.
          • Jason,

            On reviewing the XMLRPC for PHP library that is included w/modx Revolution is there any reason not to use the current version of XMLRPC for PHP 2.1 or is the version bundled w/ Revolution current and secure enough to work with? I’m asking because I don’t know and trust that you do.

            Cheers,

            Jay
              Author of zero books. Formerly of many strange things. Pairs well with meats. Conversations are magical experiences. He's dangerous around code but a markup magician. BlogTwitterLinkedInGitHub
            • The version in Revolution is XMLRPC for PHP 2.2 and should be fine. This will be upgraded to 2.2.1 soon to address an error with PHP 5.2.2, but should be fine to work with at 2.2 (unless you are using PHP 5.2.2).
              • Cool, thanks. Will look at it.
                  Author of zero books. Formerly of many strange things. Pairs well with meats. Conversations are magical experiences. He's dangerous around code but a markup magician. BlogTwitterLinkedInGitHub