views:

106

answers:

5

Possible Duplicate:
Best PHP framework for an experienced PHP developer?

I'm not new to PHP, I'm experienced in several other languages as well. I'm currently using a lot of c# and ASP.net at work. I would like to get back into PHP for my personal programming but am wondering what frameworks are out there and what ones are recommended or should I just use straight PHP and code it all myself?

A: 

I've used CakePHP before, and it worked pretty well. It takes a little while to get your head around The Way To Do Things, but after that, it's pretty smooth. It's not exactly lightweight, so consider that when deciding. I've heard that it is closely modelled on Rails, so learning Cake might give you some transferable knowledge at least.

nickf
+3  A: 

I strongly recommend Zend Framework. I've tried a fiew other frameworks, and I always come back to ZF. The code is well organized, well documented. There is NO global function; everything is structured into classes and the class names always tell you where the code is located.

Yanick Rochon
+2  A: 

I you want something light without a heavy learning curve (I use Zend in the office, you don't want to go that route unless you have a LOT of time to study) then I would recommend CodeIgniter. Very straightforward and easy-to-use.

Cody Snider
+1  A: 

Symfony is the one you should try.

DailyMotion is powered by Symfony.

Ngu Soon Hui
I've looked through this and it seems to be interesting. I'll give this a shot for a few weeks and see how it goes.
Justin808
A: 

Hello,

I am going to go against everyone here. I have been developing since the good old ASP and VBScript days.

I have tried, for some time CodeIgniter was pretty good, have looked at CakePHP and used Symfony which is pretty neat. Also I have spent some time with Ruby.

BUT I would say stick with normal, good ol PHP. (this of course depends on the size of your project). But for smaller jobs, pure PHP is great.

I highly highly recommend using a great HTML templating system.
H20 over at git hub is amazing. It is completely stolen from the Django project and allows you to create great HTML templates that can inherit base templates. It is really simple but will remove the need to echo html strings. You basically pass the template your variables. http://github.com/speedmax/h2o-php

Lastly, the biggest recommendation is I can make is use a cool DB. Have a look at MongoDB, it is a document based storage, but it will save you hours and hours trying to persist objects in a relational database when you can simple save and retrieve complex objects from Mongo.

With all this in hand I think you could build some really big, clean and maintainable.

I say this based on how hard it is to come back to a project like Cake, or Codeignigter after 6 - 12 months and how long it takes me to remember whats going on and where everything is. I have found it actually quite difficult to come back to Ruby on Rails, and CodeIgnigter and found small tidy PHP was alway the easiest.

I also hate that when I have update say Ruby+Rails how many things break and dont work. That could be a lot more pain than you need.

• So simplicity and elegance. • Easy to pick up again in 6-12 months. • Small amounts of code. • Smart database. • Easy for other people to use and debug. • Bare bone PHP should be fast and scale nicely.

While PHP is still one of the most convenient languages around, I find the syntax quite painful. And lack of some connivence operators.

eg

$obj = {value1:"john", value2:"is cool", value3:[1,2,3]}; 

Personally I think it was a real pity this didn't get put in, much to a lot of debate.

Python on google app engine is also fantastic, great database, and django templates (hence my H20 and Mango DB recommendations).

Good luck, John.

John Ballinger