New PHP framework - Jackal

Discussion for various published PHP frameworks, including Zend Framework, CodeIgniter, Kohana, CakePHP, Yii, Symfony, and others.

Moderator: General Moderators

New PHP framework - Jackal

Postby lukekeith » Wed Jan 19, 2011 12:16 am

Fellow PHP developers, my name is Luke Keith. Two years ago Samuel Dillow and I started developing Jackal, an open source PHP framework that we believe will change the way people think about PHP frameworks.

Image
http://www.jackalphp.com

We are still very much in our infancy, but we have released v1.1.3 online for download with an interactive demo. We would love to get some honest feedback on our framework. We are also looking for a few developers to help build our community.

Here are a few brief pieces of info about Jackal.

* Incredibly light weight
* Only loads what it needs when it needs it
* An incredibly sexy model
* Triggers are freaking easy
* 100% resource protection
* URL flags
* MVC

... and much much more.

I have put together two tutorials to help you get started and you can also read our online documentation. We have also published a few of our home-grown modules and libraries for download.

Looking forward to some feedback!

Regards,
Luke Keith
lukekeith
Forum Newbie
 
Posts: 2
Joined: Wed Jan 19, 2011 12:00 am

Re: New PHP framework - Jackal

Postby lukekeith » Wed Jan 19, 2011 12:38 am

Here are a few code examples so you can see what I am talking about... this of course barely touches on what we have done with Jackal, but it should give you a small taste.

Create a new page
If you want to create a new page, why should you have to add a new method to your controller class that calls your page and passes in relevant data? Why can't it be as easy as the following...

Step 1: Create a new folder called "Blog" in the "private/modules" directory

Step 2: Create a file called "view" inside your new "Blog" folder.
Syntax: [ Download ] [ Hide ]
echo "Hello world!";
 


Step 3: Now pull it up in the browser by going to yoursite.com/Blog/view

Save a record to the database
Okay, models have always been somewhat of a pain to use and not very intuitive. So why can't I do something like this....

Step 1: Create your model
Syntax: [ Download ] [ Hide ]
class BlogModel extends JackalModel {
    // Define every table of your Blog in YAML
    protected function getDefinition() {
        return "
            blog:
                !blog_id        : int not null auto_increment
                headline        : varchar(200)
                body            : text
                created         : datetime
        "
;
    }
}
 


Step 2: Your insert script
Syntax: [ Download ] [ Hide ]

// This data can obviously come from anywhere, a form, ajax request, etc. the
// point is that all you need is an array of data that matches the model definition
$entry = array(
     "headline" => "My new blog entry",
     "body" => "The body of my new blog entry"
);

// Insert the record
Jackal::model("Blog/save", $entry);
 
lukekeith
Forum Newbie
 
Posts: 2
Joined: Wed Jan 19, 2011 12:00 am

Re: New PHP framework - Jackal

Postby John Cartwright » Thu Jan 20, 2011 3:23 pm

This is a very loose interpretation of MVC. Anyone looking for the traditional 3 tier seperation, routers, dispatchers, front controllers, etc. you will not find it here. There has been a general shift away from Page controllers with better support of OOP in recent years.

Interesting welcome graphic though. It got me to download the framework (which is rare ;)).

This framework I would find more suitable for beginners working on personal projects, where design architecture, and separation of concerns, oh and TESTING! are not as important..

I certainly would not call it revolutionizing the PHP world uses frameworks. That is an absurd statement. In fact, after reading that my expectations were really high, only to be destroyed when I got into the code ;) Call a dog a dog, or however that saying goes.

Overall, not bad. Keep up the development, I'm sure there is a niche of people that would make good use of this.
Code: Select all
if ($toBe || $notToBe) echo 'That is the question'; 

NEW HERE?: Please read the Forum Rules, and take the Forum Tour before posting!
User avatar
John Cartwright
Site Admin
 
Posts: 11470
Joined: Tue Dec 23, 2003 3:10 am
Location: Toronto

Re: New PHP framework - Jackal

Postby Zyxist » Fri Jan 21, 2011 4:33 am

I downloaded the code, and I was expecting a framework, but I found a nearly featureless MVC (I hope) stack. There are still lots of things you should do in order to make it usable by most of people, so I would not write "Writing incredibly powerful web sites and web apps has never been this easy".

The things that do not work:

1. Complete mess when it comes to the framework-user code separation. Looking at the code, you can't distinguish between what you should touch in order to build a website and what you shouldn't, if you do not know how it works.

2. No single convention. In one place, you use foo_bar() names, in other: fooBar()

3. You have classes, objects etc. but I would not call it OOP. Especially there is a Jackall class which has nothing to do with OOP design.

4. No namespaces, no autoloading... wake up, it's a PHP 5.3 time :). This is a well-accepted standard. Just use it instead of inventing your own exotic solutions that make the integration with any other component much harder, especially if your framework does not provide most of the typical features.

5. Poor documentation, and tutorial code base. Right now, they are completely useless due to the lacking pages.
User avatar
Zyxist
Forum Contributor
 
Posts: 104
Joined: Sun Jan 14, 2007 11:44 am
Location: Cracow, Poland

Re: New PHP framework - Jackal

Postby alex.barylski » Thu Feb 10, 2011 9:02 am

Wrong community to preach 'ground breaking' bud. :)

Not even looking at the code, I already dislike the fact your URI references 'blog/View'??? Bad design choice, IMO, are you trying to circumvent the use of controllers proper?

Cheers,
Alex
alex.barylski
DevNet Evangelist
 
Posts: 6259
Joined: Tue Dec 21, 2004 6:00 pm
Location: Winnipeg


Return to PHP - Frameworks

Who is online

Users browsing this forum: No registered users and 0 guests