ExpressionEngine CMS
Open, Free, Amazing

Thread

This is an archived forum and the content is probably no longer relevant, but is provided here for posterity.

The active forums are here.

Micro frameworks

February 19, 2008 4:44am

Subscribe [9]
  • #1 / Feb 19, 2008 4:44am

    xwero

    4145 posts

    The day before yesterday i read about EpiCode and today there is Framework (the heart of the frog cms). The latter seeks out the competition with CodeIgniter as they reference to it and do a comparing test (is the welcome message the hello world for frameworks?).

    Epicode is not really a framework because it only routes urls. Even in the blog comments people call it a utility. It made me think about what is considered to be a framework. A while a go there was another blog post comparing frameworks and the person who wrote it didn’t consider CodeIgniter to be a full featured framework in comparison with zend, cakephp and symfony. I don’t remember which features he mentioned but i know Derek Allard asked for his point of view on CodeIgniter in the comments.

    I think the Frog framework seems to be the minimum on what can be considered to be a framework. It seems to be a good start if you want to learn how frameworks operate. Browsing through the example code of the framework i get the feeling i’m looking at a naked framework. For instance the default method for the controller gets defined in the bootstrap file (CodeIgniter does it in the router library). The router of the framework is the dispatcher class and the session is the flash class.

    I like the clean code of both of the frameworks, and performance tips in the heading of the epicode blog :) I think framework is going to be more a competitor for Kohanaphp than for CodeIginter because it’s php5 only and they want to appeal people who want everything in a tiny package. I think if CodeIgniter drops the php4 support people will be shopping for frameworks like this one, or not?

  • #2 / Feb 19, 2008 5:01am

    Thoer

    111 posts

    If I worried about the size of CodeIgniter, I’d still use pure PHP. On the other hand it’s been stated that CI will support php4 as long as there’s reason to do so. I think we’ll both use php6 by then and CI will be the best framework for that too, I’m sure. 😉

  • #3 / Feb 19, 2008 7:09am

    xwero

    4145 posts

    It’s not only about the size of the framework but smaller frameworks tend to be easier to learn to use and adapt. For instance a member on the forum was confused why the session library used cookies instead of the native php session storage after he has written an authentication library using the CI session class.

    A lot of people want to extend the CI database class but there is no easy way to do it. You have to go through the code to see how the database class is structured to find out you can copy the driver directory and give it a new name and rename the directory, filenames en classnames of the driver to make a custom database driver. (I found out reading a comment from Derek Jones)

    A developer starting with a framework sees it first as a tool and wants to start creating apps/sites going through as little documentation as possible.(I’ve been guilty of that sin too). Once you have a feel for the framework you start exploring the code.

    A micro framework gives a developer the possibility to look at the code and understand how the code works from the start which is a benefit for the developer and the creators.
    I don’t think it’s not about who as the best framework, which is a subjective view, but which framework code is the most appealing to browse through.

  • #4 / Feb 19, 2008 10:37am

    John Fuller

    779 posts

    I think if you really want to piece together a more customized framework then you should look at the Zend Framework.  You can use as much or as little of it as you like.

  • #5 / Feb 19, 2008 11:04am

    xwero

    4145 posts

    @John Fuller: I never tried the zend framework that thoroughly. I’ve become curious what would be the smallest essential framework (MVC and sessions). I’ve browsed trough the zend framework documentation but i couldn’t find which files you really need. Could you set me in the right direction? In the documentation i did find i need the components Zend_Controller, Zend_Db, Zend_View, Zend_Session.

    I realized the frog framework has no config library but i guess that is not really an essential library?

  • #6 / Feb 19, 2008 11:12am

    John Fuller

    779 posts

    ve browsed trough the zend framework documentation but i couldn’t find which files you really need.

    That is the beauty of the Zend Framework.  You don’t need anything.  Pick what you want and dump the rest.  You have your own home made framework but need a “date” library?  Get Zend Date.  Need Flickr?  Zend has that too. 

    Some libraries do have a lot of dependencies though.  The easiest way to use the Zend libraries is to just get the whole thing.  If you want to use the pieces you might have to go through the code and change the paths of the includes.

    As a more traditional framework, start with Zend Controller.  In fact, the docs on Zend controller give you a great overview.

    Ultimately it may not be as minimal as the others you mentioned but why would go for minimal just for the sake of being minimal?  I think Zend gets close enough and the framework is backed by a big name.

    I still use CodeIgniter but the ZF is a good toolbox.

  • #7 / Feb 19, 2008 11:47am

    xwero

    4145 posts

    Ultimately it may not be as minimal as the others you mentioned but why would go for minimal just for the sake of being minimal?  I think Zend gets close enough and the framework is backed by a big name.

    I think it would be fun to check which framework would have the smallest footprint when it’s striped to the minimum.

  • #8 / Feb 19, 2008 11:53am

    Lone

    350 posts

    I still use CodeIgniter but the ZF is a good toolbox.

    Out of interest why do you prefer CI? You seem to always give Zend a good wrap each time 😊

  • #9 / Feb 19, 2008 12:33pm

    John Fuller

    779 posts

    I prefer both.  I use Zend libraries if I need them.  For my needs CodeIgniter is more functional out of the box.  Also, I get most of my work from the ExpressionEngine community (I mainly do PHP work for personal projects) so I prefer to stick with the EllisLab family.

  • #10 / Feb 19, 2008 1:17pm

    Craig A Rodway

    189 posts

    I found Zend a pain in the arse to get working and couldn’t understand where to do the basic view-in-view or template pages.

    Lol.. Frog Framework for me:

    Page rendered in 0.7710 seconds.
    Use 380.67 kb of memories.

    I think micro frameworks have a place; and it all depends on what you want personally from a framework or what a webapp demands. For me, I choose Code Igniter for the amount of libraries and helpers available.

  • #11 / Feb 19, 2008 1:22pm

    xwero

    4145 posts

    Lol.. Frog Framework for me:

    Page rendered in 0.7710 seconds.
    Use 380.67 kb of memories.

    What is the time for a CI welcome rendering on your server?

  • #12 / Feb 19, 2008 1:25pm

    Craig A Rodway

    189 posts

    Lol.. Frog Framework for me:

    Page rendered in 0.7710 seconds.
    Use 380.67 kb of memories.

    What is the time for a CI welcome rendering on your server?

    Code Igniter, on same machine:

    Page rendered in 0.2253 seconds

  • #13 / Feb 19, 2008 1:49pm

    xwero

    4145 posts

    Lol.. Frog Framework for me:

    Page rendered in 0.7710 seconds.
    Use 380.67 kb of memories.

    What is the time for a CI welcome rendering on your server?

    Code Igniter, on same machine:

    Page rendered in 0.2253 seconds

    We have a winner 😊

  • #14 / Feb 19, 2008 2:33pm

    Michael Wales

    2070 posts

    Use 380.67 kb of memories.

    I just can’t get over the grammatical mistakes… way to much smiling on my part for efficient coding to result.

  • #15 / Feb 19, 2008 2:37pm

    Craig A Rodway

    189 posts

    @Michael, hehe 😊 Fancy dress anybody?

    // all constants that you can define before to costumize your framework

.(JavaScript must be enabled to view this email address)

ExpressionEngine News!

#eecms, #events, #releases