Framework...ya

Ye' old general discussion board. Basically, for everything that isn't covered elsewhere. Come here to shoot the breeze, shoot your mouth off, or whatever suits your fancy.
This forum is not for asking programming related questions.

Moderator: General Moderators

Post Reply
User avatar
shiznatix
DevNet Master
Posts: 2745
Joined: Tue Dec 28, 2004 5:57 pm
Location: Tallinn, Estonia
Contact:

Framework...ya

Post by shiznatix »

I know this question has been asked a million times but please, hear me out for a minute.

I started at my company and the website they had up was a complete piece of junk. So I go about rebuilding it. I have a quite simple framework that I have been using for just about every website I have made in the past few years and it has been running perfectly. It's simple, easy to use, and it makes my life 1234234 times easier. So I make a complete new website with this framework so the site will not suck so hard and that when I need to make a change in anything I can easily do it.

Now walk in the Finns. I don't know if any of you have ever had to deal with Finnish people but they are so afraid of change is insane. It requires 10 of them a few months to decided the smallest thing. Then comes in the fact that, even though I am the only IT person that works directly for my boss, he does not listen to a word I say. So now I have this shiny new perfect website ready to launch and they are like 'does it support <buzzword />?' I try and I try to explain that we should not bloat something that does not need bloated but like I said the Finns don't listen to me.

So the Finns conclusion is that we need to run our site on a huge already tested framework. Now ok whatever but after looking at all the big frameworks out there its crap. I need flexability, I need to use my templating engine (PHPTAL), I just want my framework to make writing code chunks easier and make code execution faster. The rest I want left up to me for maximum flexability because I have to integrate into other random things (such as vBulletin).

So the frameworks I have tried and the problems I found:

Zend Framework Problems:
-Documentation was lacking even basic stuff (how do I run a query for christ sakes!? and how do I only select 2 fields from a table instead of all fields!?)
-Integrating PHPTAL was hackish and even though there was a view script someone wrote to do this there was no documentation on it so I had no idea what to do with it

Symphony Problems:
-I could not even get a hello world page going. It was the most complicated thing I have ever seen and there was no true documentation on it.
-The download package for each tutorial was different so which one did they even want me to use? Each tutorial on their own site had a different framework package so I had no idea where to even start
-No way in hell would I use something so complicated

Zoop Problems:
-No documentation at all
-Crappy code
-No

Seagull Problems:
-I want a framework, not a CMS
-Super integration of smarty when I really hate smarty.

So I am nearly at my wits end. There is no way to convince my boss that his Finnish counterparts are just being idiots and trying to overgeneralize a framework based on the argument "we don't know what we will need in the future" and "can you promise your framework will work perfectly with 1million users?". No no no! We have 5000 users, if we have changed nothing by the 1million marker then you have obviously fired me and not hired a replacement for like 2 years.

So my question is, does anyone know how to solve the problems that these frameworks pose or maybe have another framework that could fulfill my needs? My needs are:

1)Using PHPTAL as the templating engine

2)Multiple languages (right now I have a text file for each page for each language. If you go to the home page and you are browsing in French then the french text file is loaded and then put into constants then the constants are set to PHPTAL variables to be displayed)

3)Not having the template be the view class. I want a real view class for each page. This way you can set your variables for the template in the view class and when it comes to processing forms you use the controller class. Every framework wants to put processing forms and the setting variables in the same function, this just makes things more cluttered and files much much much longer. Why not separate them into different classes easy breazy style?

4)Easily extendable. I don't want restrictions. I need to be flexable. The only reason I am doing this in the first place is because the Finns want a brand name instead of what they actually need.

So if one of those frameworks can meet my requirments somehow please let me know. Otherwise, if you know another framework that can meet those requirments let me know of that too. Thanks.
User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Post by Chris Corbyn »

symfony is not complicated if you're already familiar with the design patterns it implements (composite view, mvc, orm, (service to worker?)).

I never followed those tutorials because they're so out of date... just read the book online, along with the wiki.

symfony for me is really fexible, well written, works in E_STRICT.

If you read the wiki for symfony you can see how to change things like the template system, or orm easily. symfony just uses php for templating which is what i love, but many people swap it to use smarty.
User avatar
shiznatix
DevNet Master
Posts: 2745
Joined: Tue Dec 28, 2004 5:57 pm
Location: Tallinn, Estonia
Contact:

Post by shiznatix »

d11wtq wrote:symfony is not complicated if you're already familiar with the design patterns it implements (composite view, mvc, orm, (service to worker?)).

I never followed those tutorials because they're so out of date... just read the book online, along with the wiki.

symfony for me is really fexible, well written, works in E_STRICT.

If you read the wiki for symfony you can see how to change things like the template system, or orm easily. symfony just uses php for templating which is what i love, but many people swap it to use smarty.
If you can link me to a real way to install symfony then please do so. I go here: http://trac.symfony-project.com/trac/wi ... bDirectory because I want to put the library in an outside directory instead of my document root. Then it says you have to have read this: http://www.symfony-project.com/book/trunk so I go there and go to what I would want to see which is: http://www.symfony-project.com/book/tru ... ng-Symfony which then tells me to install the sandbox which is NOT what I want. I want the framework skeleton to start with. I have to have the command symfony installed on my machine (why the hell do I need that anyway!?!?) to start the install or something but I don't have this command so thats the end of the line.

So, if there is a real way to install this let me know. Otherwise it's staying under the 'far too complex' category for me.
User avatar
Chris Corbyn
Breakbeat Nuttzer
Posts: 13098
Joined: Wed Mar 24, 2004 7:57 am
Location: Melbourne, Australia

Post by Chris Corbyn »

Intalling it?:

Code: Select all

pear channel-discover pear.symfony-project.com
pear install symfony/symfony
That's installed now.

Starting your first app:

Code: Select all

cd public_html/
mkdir myproject
cd myproject
symfony init-project myproject
symfony init-app mywebsite
symfony init-module mywebsite homepage
Now just virtualhost the "web" directory under a primary hostname and you'll have a working app, albeit with default symfony pages.

The actual book is really easy to read if you grab yourself a coffee and just work through it trying out the code as you go:

http://www.symfony-project.com/book/trunk
User avatar
RobertGonzalez
Site Administrator
Posts: 14293
Joined: Tue Sep 09, 2003 6:04 pm
Location: Fremont, CA, USA

Post by RobertGonzalez »

Have you looked at Solar? It is one of the cleanest written pieces of code (on par with Swift for PHP5) I have ever seen. It was originally written by Paul M Jones (the guy to wrote the Savant template handler). It has great documentation and is easy to use, if you have PHP5.
Post Reply