We launched new forums in March 2019—join us there. In a hurry for help with your website? Get Help Now!
    • 33101
    • 46 Posts
    Just a note for anyone that likes Kohana.

    http://github.com/yehosef/Mohana

    enjoy
      • 32674
      • 101 Posts
      1. great looking bridge. (bummer evo, not revo though wink)

      2. I personally really like the looks of the kohana validation lib --- I wonder (out loud) if it could peacefully co-exist with -- or be a drop in replacement for -- the xPDO 2.0 xPDOValidator class? I’ll have to poke my nose around Mohana a bit to see what you’ve done, and poke my nose into the xpdo validator a bit more extensively too.

      3. Thanks for posting/sharing this.
        • 33101
        • 46 Posts
        Quote from: wowzow at May 11, 2010, 11:34 AM

        1. great looking bridge. (bummer evo, not revo though wink)

        I, as most people, have a lot more experience with Revo. Also I think Evo is still too green - Once it reaches a full release then I’ll evaluate it again.



        2. I personally really like the looks of the kohana validation lib --- I wonder (out loud) if it could peacefully co-exist with -- or be a drop in replacement for -- the xPDO 2.0 xPDOValidator class? I’ll have to poke my nose around Mohana a bit to see what you’ve done, and poke my nose into the xpdo validator a bit more extensively too.

        I don’t really know anything about xpdo - it’s not really clear to me what the xPDO gives me over any other ORM solution. I looked at some discussions about it - was confused and so went along.

        The Validation library is ok - but what you really want to keep your eyes on is the next version of Formo - http://bmidget.tumblr.com/ It has it’s lineage in standard html forms, hence the name, but the next version will be a much more generic data validation machine. The blog has some teasers about what it’ll be able to do. Again, much of the discussion is in the form aspect of it, but the core will be light-weight and it will be natural to embed it in a Model or anywhere else you need data and validation. Once this is released, Mohana will migrate to KO3.



        3. Thanks for posting/sharing this.

        Thanks for checking it out. I don’t always check these forums, but any issues/questions can be posted to github.
          • 9207 ☆ A M B ☆
          • 2,475 Posts
          I, as most people, have a lot more experience with Revo. Also I think Evo is still too green - Once it reaches a full release then I’ll evaluate it again.

          I think you got these backwards wink

          I’m working on some validation / form-generation stuff. The Kohana libraries should be able to be integrated with Revo easily since it’s all OO stuff... you’d just have to extend the class.
            • 33101
            • 46 Posts
            Quote from: Everett at May 12, 2010, 12:16 AM

            I, as most people, have a lot more experience with Revo. Also I think Evo is still too green - Once it reaches a full release then I’ll evaluate it again.

            I think you got these backwards wink

            Indeed I did smiley Thanks for the correction


            I’m working on some validation / form-generation stuff. The Kohana libraries should be able to be integrated with Revo easily since it’s all OO stuff... you’d just have to extend the class.

            For basic form generation, I’d recommend looking at Formo - a module. Again, the current version between the next version is like night and day, but it’s still very handy. Formo 1 has a lot of quirks, especially in radio/checkbox/select elements, but it’s very usable.

            The basic approach in Mohana is to load the kohana classes in the MODx execution path - then the autoloader of Kohana takes care of the rest. When you want the ORM - you just do a

            foreach (ORM::factory->where(array('status'=>true,'age>'=>20))->find_all() as $user) {
              echo View::factory('user/short_bio',array('user'=>$user));
            }


            anywhere in MODx where php can be used. I don’t have time now, but I’d really like to see someone take this approach and rewrite Ditto/Wayfinder using Kohana. One of the _major_ problem with MODx is the lack of a real templating solution that can handle control structures and loops (yes, I’ve tried PHx). Using Kohana with Views, brings this into the realm of possible. With a little bit of creativity, you could make a plugin to save chunks into the view folder of the Kohana installation and then create views inside MODx. I don’t remember how the MODx admin handles php in chunks, but if not, then I was thinking a templating solution like Twig.

            Unfortunately, I don’t have time right now to implement these ideas - but my goal is that by opening it up, other people can start contributing code and turn MODx into something even more powerful.

              • 17499 ☆ A M B ☆
              • 872 Posts
              Quote from: yehosef at May 12, 2010, 02:15 AM


              For basic form generation, I’d recommend looking at Formo - a module. Again, the current version between the next version is like night and day, but it’s still very handy. Formo 1 has a lot of quirks, especially in radio/checkbox/select elements, but it’s very usable.

              The basic approach in Mohana is to load the kohana classes in the MODx execution path - then the autoloader of Kohana takes care of the rest. When you want the ORM - you just do a

              foreach (ORM::factory->where(array('status'=>true,'age>'=>20))->find_all() as $user) {
                echo View::factory('user/short_bio',array('user'=>$user));
              }


              anywhere in MODx where php can be used. I don’t have time now, but I’d really like to see someone take this approach and rewrite Ditto/Wayfinder using Kohana. One of the _major_ problem with MODx is the lack of a real templating solution that can handle control structures and loops (yes, I’ve tried PHx). Using Kohana with Views, brings this into the realm of possible. With a little bit of creativity, you could make a plugin to save chunks into the view folder of the Kohana installation and then create views inside MODx. I don’t remember how the MODx admin handles php in chunks, but if not, then I was thinking a templating solution like Twig.

              Unfortunately, I don’t have time right now to implement these ideas - but my goal is that by opening it up, other people can start contributing code and turn MODx into something even more powerful.



              I think that the whole point behind chunks in MODx is to not use PHP in html code.
              In revolution you can use output filters and create custom one (native phx for Revolution).
              IDK, but it might be possible to drop Kohana code in output filters (if you want to keep the non native php code in chunk behavior)