1. Advertising
    y u no do it?

    Advertising (learn more)

    Advertise virtually anything here, with CPM banner ads, CPM email ads and CPC contextual links. You can target relevant areas of the site and show ads based on geographical location of the user if you wish.

    Starts at just $1 per CPM or $0.10 per CPC.

The best framework

Discussion in 'PHP' started by rmmrj, Aug 15, 2013.

  1. #1
    I am using Smarty framework for building websites in PHP. Is this the best one? If not please recommend me the best one.


    Thank you,
    Ramesh
     
    rmmrj, Aug 15, 2013 IP
  2. DJV

    DJV Member

    Messages:
    42
    Likes Received:
    7
    Best Answers:
    0
    Trophy Points:
    48
    #2
    Everyone i talk to says Zend? I guess everyone has their preference!
     
    DJV, Aug 15, 2013 IP
  3. samyak

    samyak Active Member

    Messages:
    280
    Likes Received:
    7
    Best Answers:
    4
    Trophy Points:
    90
    #3
    Smarty isn't really a "framework" in traditional meaning. Its an template engine meant to separate application logic and content from its presentation.

    If you are talking about Application frameworks, such as Zend or CodeIgniter, then there is not a really a Best one. All of them have their pro and cons. Zend seems to be favorite or many programmer these days, but personally I feel that Zend is too bulky for small and medium projects.
     
    samyak, Aug 15, 2013 IP
  4. samyak

    samyak Active Member

    Messages:
    280
    Likes Received:
    7
    Best Answers:
    4
    Trophy Points:
    90
    #4
    Found a site that compare all the frameworks. http://www.phpframeworks.com/
    You can compare all available frameworks and choose one based on the modules you need.
     
    samyak, Aug 15, 2013 IP
  5. Ricardooo

    Ricardooo Peon

    Messages:
    4
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    1
    #5
    I choose codeigniter, to small and medium projects, but i never try de Zend
     
    Ricardooo, Aug 15, 2013 IP
  6. livedating

    livedating Active Member

    Messages:
    161
    Likes Received:
    0
    Best Answers:
    1
    Trophy Points:
    83
    #6
    I recommend you to use Kohana - its easy to start, extremely fast and highly customizable. I'm using it for many years and I'm happy with it.
     
    livedating, Aug 16, 2013 IP
  7. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,998
    Best Answers:
    253
    Trophy Points:
    515
    #7
    Personally I think "frameworks" are generally sleazy shortcuts that result in bloated crap code, usually used to cover up the ineptitude of the developer. Rarely if ever have I seen one that offered any legitimate benefit over writing code directly.

    Though as samyak said, "smarty" isn't a real framework, it's a template engine -- an even DUMBER bit of bloated bullshit that pisses me off every blasted time I come across it. Given that PHP is itself basically a template engine all by itself... I fail to comprehend why the mike foxtrot hotel ANYONE would use it by choice, apart from a complete ignorance on how to use PHP properly. Running an interpeted preprocessor on top of a interpreted preprocessor has to be some of the dumbest foxtrot sierra out there.

    Forget that crap and learn to do things yourself properly -- you'll quickly find it's less code, less headaches, easier and faster to develop and maintain -- basically ALL the things these stupid 'frameworks' CLAIM to deliver, and provide the exact opposite of.
     
    deathshadow, Aug 17, 2013 IP
  8. ekim941

    ekim941 Member

    Messages:
    74
    Likes Received:
    7
    Best Answers:
    7
    Trophy Points:
    33
    #8
    I think you will find that Symphony2 has a lot of support and is fairly easy to learn. It uses the twig template engine which is also easy to learn.
    The problem I'm finding with frameworks is that they are incredibly slow. I like the concept of MVC but, in production, it is much slower than using php in your presentation code.
    Maybe I'm doing something wrong or maybe I'm just old-fashioned. I've written several applications that just use php without a template engine and they are much faster than the ones I have made using a framework and template engine.
    In fact, I have never even put one of my framework projects into production because they run so slow on a local machine.
     
    ekim941, Aug 17, 2013 IP
  9. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,998
    Best Answers:
    253
    Trophy Points:
    515
    #9
    That's because the entire MVC concept was created for EVENT DRIVEN software and environments, something PHP is decidedly not. Shoe-horning the MVC concept into a top down executing language like PHP is another halfwit practice, no matter how many so-called 'experts' promote it's use.

    It's akin to the folks who said use objects for EVERYTHING, which was all the rage four or five years ago. It's a sick fad that in real world practice should be filed alongside all the other sick buzzwords like web 2.0, and idiotic 'new shiny' crap like HTML 5 that offers zero real world improvements.
     
    deathshadow, Aug 17, 2013 IP
  10. techinfocomp

    techinfocomp Peon

    Messages:
    2
    Likes Received:
    0
    Best Answers:
    0
    Trophy Points:
    1
    #10
    If you just asking about to manage your design part and Program Part the yes Smarty is best.

    But if you asking about Design part (HTML), Programming Part and Database part then No Smarty is not Best choice.
    Try CodeIgniter (codeigniter.com) easiest MVC Framework.
     
    techinfocomp, Aug 17, 2013 IP
  11. samyak

    samyak Active Member

    Messages:
    280
    Likes Received:
    7
    Best Answers:
    4
    Trophy Points:
    90
    #11
    I agree with what deathshadow told about smarty template engine. Its such an redundant idea. It is supposed to free the presentation with the logic, so that designers can work independantly of the programmers who create the application logic. However learning curve of Smarty syntax is way steeper than the learning PHP for designers.
     
    samyak, Aug 18, 2013 IP
  12. DeanIM

    DeanIM Greenhorn

    Messages:
    25
    Likes Received:
    0
    Best Answers:
    2
    Trophy Points:
    21
    #12
    Surprised noone has mentioned Yii yet!
    Yii used to be the new kid on the block but now they're close to releasing Yii 2.0. They have a great community, wiki, lots of extensions and once you get used to the workflow your project development will be a matter weeks or even days!
     
    DeanIM, Aug 20, 2013 IP
  13. crazyblogger

    crazyblogger Active Member

    Messages:
    430
    Likes Received:
    5
    Best Answers:
    1
    Trophy Points:
    63
    #13
    If I have to choose, I would say codeignitor or Laravel.
     
    crazyblogger, Aug 21, 2013 IP
  14. tobalsan

    tobalsan Well-Known Member

    Messages:
    63
    Likes Received:
    8
    Best Answers:
    0
    Trophy Points:
    108
    #14
    Such thing as "Best Framework" - in an absolute meaning - does not exists.

    It's like asking "What's the best car" or "What's the best CMS" (even if a lot of you will be eager to answer "Wordpress). The real thing to ask first is : for what use ? Depending on what you want to build, you'll be better with different tools.

    In a more "general" way, let's say you want the jack-of-all-trades PHP framework, you'd be fine with either Symfony, Laravel (which is built on top of Symfony components, btw), or ZendFramework.
    Actually even CodeIgniter or FatFreePHP would do.

    In the end it's always about the developer(s).
     
    tobalsan, Aug 23, 2013 IP
  15. sources68

    sources68 Member

    Messages:
    74
    Likes Received:
    1
    Best Answers:
    0
    Trophy Points:
    38
    #15
    I use Yii Framework, it best performent
     
    sources68, Aug 23, 2013 IP
  16. ChiragKalani

    ChiragKalani Active Member

    Messages:
    41
    Likes Received:
    2
    Best Answers:
    3
    Trophy Points:
    73
    #16
    I think Phalcon is best framework . It is fatest framework among all the framework.
    Visit this URL for more info http://phalconphp.com/en/
     
    ChiragKalani, Aug 23, 2013 IP
  17. deathshadow

    deathshadow Acclaimed Member

    Messages:
    9,732
    Likes Received:
    1,998
    Best Answers:
    253
    Trophy Points:
    515
    #17
    Never heard of it... let's see...

    "Best for web 2.0 development" -- so they're nothing but market-speak bullshit idiots who don't know enough about the Internet to open their yaps on the subject?!? Sad when I have that reaction JUST from opening their website.

    ... and if that website is typical of what their framework produces given that it's a complete and utter inaccessible halfwit train-wreck of how NOT to build a website... Let's just say things aren't looking very bright for it. If the front end made by it's dev's is crap, how can what it does under the hood be any good?

    Of course digging into it by all appearances I see the same bloated useless crap as every other PHP framework I've ever seen. When unpacked the distribution is larger than many forum softwares, that's usually a poor start. When the comments outnumber the actual code in most every file 10:1 or more, it's probably piss-poorly coded with needlessly cryptic names on things... when it's creating a fat bloated object that seems to wrap a PDO object for no good reason instead of *SHOCK* extending the PDO object, put a fork in it, it's done.

    Even just idiotic little bits of crap like this:
    foreach($params as $name=>$value)
    	$this->params[$name]=$value;
    Code (markup):
    Showing they don't know enough PHP to even be THINKING about writing code for others... (it's called array_merge!)... or worse:

    return $this;
    Code (markup):
    Yup, just another crappy off the shelf framework that people are DUMBER for it even existing.
     
    deathshadow, Aug 24, 2013 IP
  18. tobalsan

    tobalsan Well-Known Member

    Messages:
    63
    Likes Received:
    8
    Best Answers:
    0
    Trophy Points:
    108
    #18
    so much free hate against a framework makes me actually want to test it. Mediocrity can't produce such rancor.
     
    tobalsan, Aug 24, 2013 IP
  19. kutchbhi

    kutchbhi Active Member

    Messages:
    130
    Likes Received:
    4
    Best Answers:
    2
    Trophy Points:
    70
    #19
    If you could recommend a book or any other suggestion to learn how to properly code without a framework , that would be much appreciated.
    Thanks
     
    kutchbhi, Aug 25, 2013 IP
  20. tobalsan

    tobalsan Well-Known Member

    Messages:
    63
    Likes Received:
    8
    Best Answers:
    0
    Trophy Points:
    108
    #20
    Please don't listen to naysayers. Usually it's people who never tried to really use a framework and feel the need to make up for it - or justify themselves - by detracting them.
    It's like saying you shouldn't use a car, because you know, it pollutes, uses gas, you have to maintain / repair it, etc. Sure, but it's still pretty damn useful.

    Still, if you don't know to properly code WITHOUT a framework then yeah, don't use one ! It only serves to provide you "shorcuts" and accelerate your development. But it definitely won't make up for any lack of good practice.
    Be sure to read all of these resources if you want to know how to properly produce PHP code (i listed them by the order you should read them in):

    http://net.tutsplus.com/tutorials/php/30-php-best-practices-for-beginners/
    http://net.tutsplus.com/tutorials/html-css-techniques/top-15-best-practices-for-writing-super-readable-code/
    http://net.tutsplus.com/tutorials/php/why-youre-a-bad-php-programmer/
    http://net.tutsplus.com/tutorials/php/psr-huh/
    http://net.tutsplus.com/tutorials/tools-and-tips/psr-duh/
     
    tobalsan, Aug 26, 2013 IP