Go Back   SitePoint Forums > Forum Index > Program Your Site > PHP
Newsletter FAQ Members List Calendar Mark Forums Read

New to SitePoint Forums? Register here for free!

SitePoint Sponsor
 
Reply
 
Thread Tools Display Modes
Old Jul 12, 2006, 03:43   #1
ArticleBot
SitePoint Articles
 
ArticleBot's Avatar
 
Join Date: Apr 2001
Posts: 0
Article Discussion

This is an article discussion thread for discussing the SitePoint article, "The CakePHP Framework: Your First Bite"
ArticleBot is offline   Reply With Quote
Old Jul 12, 2006, 03:43   #2
GarrettB
SitePoint Enthusiast
 
Join Date: May 2006
Posts: 30
Very nice! I hope to use this in my PHP Practices!
GarrettB is offline   Reply With Quote
Old Jul 12, 2006, 03:57   #3
dg_den_golotyuk
PHP Brainiac
 
dg_den_golotyuk's Avatar
 
Join Date: Jul 2006
Location: Kiev, Ukraine
Posts: 335
I'm to use this framework from recent time. I like it very much. It is a good tool for middle-complexity web-projects
dg_den_golotyuk is offline   Reply With Quote
Old Jul 12, 2006, 04:02   #4
spinmaster
SitePoint Evangelist
 
spinmaster's Avatar
 
Join Date: Mar 2005
Posts: 458
Nice read... another Framework worth a look for small to medium size webapps is Code Igniter! I like CI even better than CakePHP.
spinmaster is offline   Reply With Quote
Old Jul 12, 2006, 06:35   #5
Dean C
SitePoint Wizard
 
Dean C's Avatar
 
Join Date: Mar 2003
Location: England, UK
Posts: 2,964
All in all, this was a very good article but when you consider the complexities of a real application I doubt I could find a use for the framework. Nevertheless, it may be useful when I want to draw something up quickly on the fly ;)
Dean C is offline   Reply With Quote
Old Jul 12, 2006, 08:50   #6
bbolte
Do or do not, there is no try
 
bbolte's Avatar
 
Join Date: Nov 2001
Location: The Central Plains
Posts: 3,213
For those that have used the framework, what has been the performance? any issues?
bbolte is offline   Reply With Quote
Old Jul 12, 2006, 09:57   #7
tparkin
SitePoint Member
 
Join Date: Jun 2006
Posts: 11
I believe the correct phrase is, "You can eat your cake and have it too". It makes sense to have your cake and eat it, but to eat your cake and still have it is a novel concept; this is why the phrase is used.

Information on the original correct saying and how it has been corrupted (and misused) can be found at: http://en.wikipedia.org/wiki/Have_one's_cake_and_eat_it_too

--tparkin
tparkin is offline   Reply With Quote
Old Jul 12, 2006, 12:51   #8
arbel
SitePoint Addict
 
Join Date: Jan 2003
Posts: 200
I'm having trouble getting the first stage to work. The scaffolding part...i've created all the files and the http://localhost/ looks good, but when I try http://localhost/notes/ I get a url not found...
arbel is offline   Reply With Quote
Old Jul 12, 2006, 15:12   #9
huseyint
SitePoint Member
 
Join Date: Dec 2005
Posts: 0
I have just started to learning Symfony Project framework. Anyone can tell which one is better?
huseyint is offline   Reply With Quote
Old Jul 12, 2006, 17:53   #10
greywire
SitePoint Member
 
Join Date: Apr 2004
Location: california, usa
Posts: 7
Two things:

First of all, it seems like the documentation links near the end of the article do not work. A bit disapointing.

I have been comparison shopping for a framework for my large (already running) application (I used codecharge studio for most of it, but am feeling the limits of this otherwise excelent program).

Cake looks nice, but I am really liking the Hierarchical Model View Controler concept employed by (and far as I can tell, only by) the Claw (http://clawphp.org/) framework. I am also concerned with how flexible the Object Relational Mapping is (it looks like no other framework is any better in this regard, ORM seems to be the standard everywhere).

I am currently torn between using Claw with my own customized models (and or Propel where it makes sense) or taking Cake and trying to add on the HMVC concept (and again writing my own custom models).
greywire is offline   Reply With Quote
Old Jul 12, 2006, 19:45   #11
-T-
SitePoint Evangelist
 
-T-'s Avatar
 
Join Date: Jun 2002
Posts: 438
After reading the article I've desided not to use Cake. It looks nice for simple things. But as soon as you start doing complex stuff, you will find yourself battling the limitations of the framework. Which is a pain in the buttocks
-T- is offline   Reply With Quote
Old Jul 12, 2006, 20:05   #12
mattymcg
Team SitePoint
 
mattymcg's Avatar
 
Join Date: Oct 2005
Location: Melbourne, Australia
Posts: 566
Quote:
Originally Posted by greywire
First of all, it seems like the documentation links near the end of the article do not work. A bit disapointing.
Hmm, they all work fine for me. What problem are you seeing?

Quote:
Originally Posted by tparkin
I believe the correct phrase is, "You can eat your cake and have it too".
LOL! I'll be sure to pass this onto our English editor!

Last edited by mattymcg; Jul 12, 2006 at 21:50.
mattymcg is offline   Reply With Quote
Old Jul 12, 2006, 20:38   #13
1PhpNut
SitePoint Enthusiast
 
Join Date: Mar 2004
Location: Shorewood, IL
Posts: 42
Quote:
Originally Posted by -T-
After reading the article I've desided not to use Cake. It looks nice for simple things. But as soon as you start doing complex stuff, you will find yourself battling the limitations of the framework. Which is a pain in the buttocks
This is not the largest application built using CakePHP, but was a cool project to develop for the client...

Not so simple application built with CakePHP

Limitations, if reached are easy to overcome...
1PhpNut is offline   Reply With Quote
Old Jul 12, 2006, 21:17   #14
Ryno
SitePoint Community Guest
 
Posts: n/a
I've just began working with CakePHP and am having a ball so far. This isn't only to do with the fact I think it's an excellent framework, but also because there is decent documentation, an active and responsive Google group, as well as IRC channel.

The times when I have needed help because of problems or lack of documentation, the group and IRC channel have always come to the rescue in quicktime!
  Reply With Quote
Old Jul 13, 2006, 17:35   #15
mutant
SitePoint Enthusiast
 
mutant's Avatar
 
Join Date: Apr 2004
Location: Gallifrey
Posts: 29
I've tried to pick up cake on several occasions to "fill the gap" on some project. In the end, I've never gotten it to fit, there is a large gap in examples.. Excluding Hello World, and Your first blog. Cake assumes you'll automagically know the proper/best/their way of doing things, and when you don't you can't really find examples of how to do things the "right way".

The html handling is also pretty basic, I had a need for multiple skins for a site based on different environmental factors, and I found myself struggling more with the skin handling than writing for the business logic of the site. Default cake installs it's own cake templates if you don't have anything there, but this makes it hard to figure out what you have to put out there.

I'm also concerned that I've not seen any "big" apps deployed in Cake. Rails has tons of examples like most of the stuff from the folks that did BasecampHQ. I've just not seen Cake really picked up in general.

One of the best parts about Cake can also be a big old pain in the ****. Cake itself is kept ENTIRELY separate from your code, I think this is AWESOME. Upgrading cake distrobutions becomes so much simpler, since you don't have to worry about hacks, and other issues it all just upgrades nicely. I did download a previous cake version, wrote a couple quick apps then upgraded it with no problem. Of course there may be times where your code might conflict, but the chances are also so much less than other frameworks.

This separation is also a major pain in the neck until you get to understand it. For the longest time I threw my hands up in the air and left it in the "development" state because everytime I tried to break out the directories, it blew up on me. I hate fighting with a framework! In the end I finally understood it, and the crazy pathfinding capabilities, but it's a pain unless you get it, and getting it can be tough.

In all, I've not seen a project through to completion with Cake, I'm certain it's because I find I can get things done faster doing it "my way", no matter how much I would like to use this type of framework.

I'd like to see some applications come out using Cake that are groundbreakers, I think the developers have a good thing, if the rest of us can wrap thier heads around it.
mutant is offline   Reply With Quote
Old Jul 14, 2006, 02:48   #16
aninfeel
SitePoint Member
 
Join Date: Nov 2005
Posts: 7
I hate coding sql,and I was going to have a try for a long time.But now I find design a class which handle sql like cake is not hard .So I give up my plan.
aninfeel is offline   Reply With Quote
Old Jul 14, 2006, 05:33   #17
dg_den_golotyuk
PHP Brainiac
 
dg_den_golotyuk's Avatar
 
Join Date: Jul 2006
Location: Kiev, Ukraine
Posts: 335
Quote:
Originally Posted by bbolte
For those that have used the framework, what has been the performance? any issues?
Many issues. This framework is a standard tool. It is not giving you all abilities you need. Before using it - you must consider a project functional specification with it. But it is really usefull for easy and middle-complexity projects
dg_den_golotyuk is offline   Reply With Quote
Old Jul 14, 2006, 05:35   #18
dg_den_golotyuk
PHP Brainiac
 
dg_den_golotyuk's Avatar
 
Join Date: Jul 2006
Location: Kiev, Ukraine
Posts: 335
Quote:
Originally Posted by Dean C
All in all, this was a very good article but when you consider the complexities of a real application I doubt I could find a use for the framework. Nevertheless, it may be useful when I want to draw something up quickly on the fly
Agreeing absolutely This framework is not for complex projects... Let me think... Can't get any framework form my head that can be used with real complex projects
dg_den_golotyuk is offline   Reply With Quote
Old Jul 14, 2006, 10:01   #19
gopherr
SitePoint Member
 
Join Date: Jul 2006
Posts: 1
dg_den_golotyuk and Dean C: Care to elaborate? All both of you mention is a Framework/Cake being inflexible and not suited for complex projects, but you give no examples. And then I take a look at your portfolio/sites, and it looks exactly like something you could (and would) do with with Cake. So, I'm just wondering ...
gopherr is offline   Reply With Quote
Old Jul 14, 2006, 10:08   #20
Capn-Bob
SitePoint Member
 
Join Date: Jul 2006
Posts: 1
Quote:
Originally Posted by dg_den_golotyuk
Agreeing absolutely This framework is not for complex projects... Let me think... Can't get any framework form my head that can be used with real complex projects
Wow.

I mean wow.

Personally I've never thought too highly of SitePoint (or, by extension, it's readership I suppose), but this level of ignorance really takes the cake (pun not specifically intended, but a happy coincidence).

Let's break down and analyze that statement:

(1) "This framework is not for complex projects".

Uhh, have you done any complex projects with it? Have you done any complex projects period?? I will grant you that getting into the framework was hard for me because of documentation, but it's gotten a *whole* lot better since then. Unless you have a medical excuse (like ADD) there is no way that a couple hours of your time won't get you into this framework.

(2) "Can't get any framework form my head that can be used with real complex projects".

K, I'm not completely sure what that means, but I can only assume by your continual references to complexity that you prefer to write sloppy, unmaintainable code.

I challange anyone to come up with a project that's too "complex" for this framework. While I agree that it's not right for *all* projects, saying it can't handle "complex" projects means you are either highly intelligent or extremely dense. More likely the latter.
Capn-Bob is offline   Reply With Quote
Old Jul 14, 2006, 10:18   #21
gwoo
SitePoint Member
 
Join Date: Jul 2006
Posts: 1
@dg_den_golotyuk
this is a nice overview of extending CakePHP
http://devzone.zend.com/node/view/id/593
This is an example of using Zend Components with CakePHP.
http://cakebaker.wordpress.com/2006/...-with-cakephp/
The same principle can be used with any third party library. For example, in http://cakephp.org/pastes we use the nice Geshi code highlighting library

@mutant
http://cakephp.org/search
will search several blogs about cakephp, the google group and the manual all at once.

@those who want to suggest building their own instead
The advantages of Open Source should be pretty clear by now. The CakePHP community is filled some very good programmers who are willing to contribute ideas, bug reports, code and help. When you need to bring in new developers to help you with a project you can have them read the manual, api, and review the many resources available. Otherwise, you have to sit there explaining how your homegrown framework works.


CakeForge has many sample applications. For instance, the code used for http://rd11.com, a blog and photo gallery site is freely available at http://cakeforge.org/projects/rdos You will also find CakeMap, which use a google maps helper and makes adding maps to a CakePHP based site easy. And the code for CakeBin is available there and gives the nice example of using Geshi within CakePHP.
gwoo is offline   Reply With Quote
Old Jul 14, 2006, 11:12   #22
mutant
SitePoint Enthusiast
 
mutant's Avatar
 
Join Date: Apr 2004
Location: Gallifrey
Posts: 29
Quote:
Originally Posted by gwoo
CakeForge has many sample applications. For instance, the code used for http://rd11.com, a blog and photo gallery site is freely available at http://cakeforge.org/projects/rdos You will also find CakeMap, which use a google maps helper and makes adding maps to a CakePHP based site easy. And the code for CakeBin is available there and gives the nice example of using Geshi within CakePHP.
I'm so done with the "blog in 20 minutes" thing. Why would anyone write thier own blog when there are tons out there that are top-notch? Lets see a sample application that has real-world use. A CMS, a simple shopping cart, show complexity by demonstrating the ease of development when developing something ususual in a shopping cart site. I think the thing that eveyone gets hung up on is that its like learning a whole new language no matter how well you know PHP, Cake is difficult when you don't know it front/back/sideways, leftwise and right, especially when you are trying to figure out how best to proceed in implementing business logic.

Perhaps that's what people mean -- CakePHP isn't suited to complex apps, not because it's not suited, but because they're not suited to having to learn this potentially complex system of doing things. I don't think there is any need to beat people up for not seeing how Cake can build complex sites -- if you support Cake, show some examples, otherwise, you're just a troll.

As a matter of fact, I think I'm going to take a page out of my own book. I'm going to try to make a simple shopping site. I'll document my trials as best I can, and report back here. Mabey that will help people understand the barriers to entry in regards to Cake.
mutant is offline   Reply With Quote
Old Jul 14, 2006, 11:38   #23
1PhpNut
SitePoint Enthusiast
 
Join Date: Mar 2004
Location: Shorewood, IL
Posts: 42
Quote:
Originally Posted by mutant
...show some examples, otherwise, you're just a troll.
It think this comment could go both ways, you say it is not capable of creating complex applications, yet there is no example given of a complex application you would like to create and found cake not suitable for it. I already posted a link above to a description of an application we created for a client through the Cake Software Foundation. If you browse the CakeForge site you will see there is a simple shopping car called bakesale, also a few CMS projects and many more are listed.

http://cakeforge.org/top/mostactive.php

Quote:
As a matter of fact, I think I'm going to take a page out of my own book. I'm going to try to make a simple shopping site. I'll document my trials as best I can, and report back here. Mabey that will help people understand the barriers to entry in regards to Cake.
This sounds like a great idea, stop by the IRC channel if you need help, someone is always online to help by answering your questions. You will find me there often too.

Java web based client:
http://irc.cakephp.org/

If you have your own IRC client
irc.freenode.net
#cakephp
1PhpNut is offline   Reply With Quote
Old Jul 14, 2006, 18:20   #24
boriscy
SitePoint Enthusiast
 
Join Date: Jun 2005
Posts: 26
Particulary if you want to download the latest manuals and software go to : http://cakeforge.org/top/mostactive.php
but the manual has some errors for examlpe in the hasAndBelongsToMany assosiations. I will write a good tutorial about assosiations because is one of the most important things to grasp to understand cakephp. I think after seeing this article here in sitepoint that cakephp migth be the best choice not only because there is an article here but because it has the most active comunity.
boriscy is offline   Reply With Quote
Old Jul 15, 2006, 14:29   #25
rhenkel
SitePoint Member
 
Join Date: Jul 2006
Posts: 1
Sorry. Couldn't reproduce the first simple exsample. How should the memo screen (http://www.cakephp.dev/notes/) appear after only creating two files (note.php and notes_controller.php) and a databse table? I see only the 404 apache message.
rhenkel is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread | Next Thread »

Thread Tools
Display Modes

 
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Sponsored Links
 
Forum Jump


All times are GMT -7. The time now is 16:48.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
Copyright 1998-2009, SitePoint Pty Ltd. All Rights Reserved