Looking for more information on how to do PHP the right way? Check out PHP: The Right Way

Reddit.com:
Why experienced developers consider Laravel as a poorly designed framework?
Jul 03, 2015 @ 11:41:03

There's a huge thread that's been going on over in the /r/php subreddit on Reddit.com with opinions on why experienced developers consider Laravel as a poorly designed framework.

I have been developing in Laravel and I loved it. My work colleagues that have been developing for over 10 years (I have 2 years experience) say that Laravel is maybe fast to develop and easy to understand but its only because it is poorly designed. He is strongly Symfony orientated and as per his instructions for past couple of months I have been learning Symfony and I have just finished a deployment of my first website. I miss Laravel ways so much.

Currently there's over 200 responses to the question with a wide range of opinions, everything from support of Laravel and its ways to the other side supporting Symfony and its structure. As is par for the course, there's also a share of "troll" comments in the mix, so be sure as you're reading through them to weed those out. There's also some interesting and enlightening things about Laravel, its structure and what it has to offer that those that may not be familiar with it could learn.

tagged: reddit rphp experienced developer laravel poorly designed framework opinion

Link: https://www.reddit.com/r/PHP/comments/3bmclk/why_experienced_developers_consider_laravel_as_a/

Reddit.com:
I feel like events are an anti-pattern
May 06, 2015 @ 10:55:00

On the /r/php subreddit frm Reddit.com, phpdevster proposes an interesting opinion - that an event system, set up with a listener and defined events, has become more of an anti-pattern in its most common implementation.

If events are only meant to be additional functionality that ALWAYS ALWAY ALWAYS should happen after a primary action is taken, how often is code really that absolute? Why are events not implemented in more flexible ways by frameworks? - that is implementing some inversion of control which would allow callers to determine which listeners would be relevant to the given context.

He illustrates his point with an example user registration system that fires a "user-was-registered" event that, in turn, fires off a series of events via a listener. He points out a pretty large flaw, though. While the functionality involved in the event is decoupled (the event itself), the behaviors defined by that event are not. Comments on the post offer some different options and solutions to the same problem including:

  • Further decoupling of the eventing process
  • Using objects with settable properties rather than just event name strings
  • The idea of using an "event store" to handle decoupling rather than more immediate code-based solutions

Have some thoughts of your own on events and decoupling? Go over and share them too.

tagged: event antipattern designpattern reddit opinion comments

Link: http://www.reddit.com/r/PHP/comments/34zp6j/i_feel_like_events_are_an_antipattern/

Reddit.com:
Frameworks, how are requests per second important?
Apr 03, 2015 @ 10:37:50

In this recent post to the /r/php subreddit on Reddit.com, AfterNite wonders why it's important to measure the "requests per second" that a framework handles (or if it is at all).

I have been using Laravel 4 for a while now. Recently I saw a benchmark here (http://blog.a-way-out.net/blog/2015/03/27/php-framework-benchmark/). There are many frameworks that were compared and compared to phalcon the requests per second seem crappy. Hearing that zend is powerful and primarily aimed at businesses how is it that a few hundred requests per second is good? I can't wrap my head around why people are using frameworks such as Zend, Laravel 5 and Symfony.

The comments on the post mention things like:

  • taking benchmarks "with a grain of salt"
  • How it relates to optimization
  • Wondering what the mean requests-per-second would be
  • What effect a datasource has on performance
  • The relation between performance and ease of use

You can read the full post or leave an opinion of your own on the full post.

tagged: requestspersecond performance optimization framework opinion reddit

Link: http://www.reddit.com/r/PHP/comments/313nc8/frameworks_how_are_requests_per_second_important/

Reddit.com:
So, what is PHP's nature? Anyone actually know exactly what it is?
Feb 13, 2015 @ 11:58:01

In this recent post to the /r/php subreddit on Reddit.com, the question is asked "what is the nature of PHP?" and how it relates to what features make it into the language and which don't.

I've heard many times that a proposed RFC/new feature got rejected by PHP internals in voting phase, since 'it does not fit the nature of PHP'. But the question is, what is PHP's nature? Does it even have a nature at all? If yes, is there a standard or guideline of what fits in PHP's nature? I think its very confusing, isnt it? Anyone actually have some insights in this?

In the comments other users provide a wide range of opinions including:

  • "I would recommend taking those types of comments with a grain of salt. PHP's nature is a very subjective topic, as you can tell by the other comments."
  • "PHP was made to make dynamic web pages at a time when webpages contained minimal dynamic content. It was made at a time when web pages doesn't required a programming language to generate."
  • "Easy to pick up and make a website for weak devs/prototypes (easy to abuse). Much of the hate for PHP is because this abuse is possible and exploited often."
  • "As someone mentioned, nobody who does any sort of web development today can ignore Javascript and they will typically be switching back and forth between Javascript and PHP every couple of minutes. This is our target user these days and as such this syntax is appropriate I think."

Check out the full post for more opinions or to voice your own!

tagged: nature language opinion reddit

Link: http://www.reddit.com/r/PHP/comments/2vmh3o/so_what_is_phps_nature_anyone_actually_know/

Reddit.com:
What changes would you like to see in PHP 7?
Jan 20, 2015 @ 12:51:08

In the /r/php subreddit on Reddit.com a question was posed to the community: What changes would you like to see in PHP 7?. So far there's 80+ answers with a wide variety of responses.

As well as massive performance improvements, PHP 7's change / feature list is already looking great. You can find most of the features that have been accepted or are under discussion on the PHP Dev Wiki: RFCs section. But what changes would make a difference to you? What would you really like to see make it in (already suggested or a new suggestion)?

Here's just a few of the suggestions made by fellow Reddit users:

  • fixing inconsistencies in naming
  • sandboxed eval
  • a complete rework of the standard library
  • the introduction of generics
  • adding enum functionality
  • type aliasing
  • stack traces for fatal errors

Check out the full post for more ideas and feedback from other members of the community too. It's an interesting list of suggestions, some that are even already in the works.

tagged: php7 changes reddit opinion community language feature improvement

Link: http://www.reddit.com/r/PHP/comments/2sx5x3/what_changes_would_you_like_to_see_in_php_7/

Reddit.com:
The purpose of a framework
Sep 19, 2014 @ 12:19:48

In this post over in the /r/PHP community of Reddit.com, there's a question about frameworks. The original poster wonders about the purpose of a framework and if they're a requirement to build any kind of application that's "worthwhile".

I read posts here from time to time, and Laravel and Symphony are mentioned a lot here, and I always get the impression that it is a must to use a framework, to build something worthwhile. A little background on myself is that I've always approached development in a cowboy coding style where I just code. I've made a system where I use the basic mysqli object in PHP for database interaction, and I use Smarty templating system to output the html/css/js. I build my own classes based on what the customer is asking for, and then obviously I make the controller pages calling the classes I made - manipulate the data and output to smarty. What would Symphony help me with - that would be hard to accomplish regularly?

Plenty of answers and opinions are shared in the comments of the post, ranging from:

  • Encouragement for Symfony2 and the development speed it accommodates
  • Building a project without a framework
  • The benefits and downfalls of using MVC and other design patterns you may not fully understand
  • A definition of what a "framework" means outside of the world of MVC

There's also a consensus among several of the posts that one of the major benefits of a framework is to provide an overall decrease in the time to market with the handy features and things it provides out of the box. What do you think? Head over and post some thoughts of your own about frameworks and where they fit in your development.

tagged: framework purpose opinion reddit mvc

Link: http://www.reddit.com/r/PHP/comments/2gub3p/the_purpose_of_a_framework/

Reddit.com:
PHP devs -What are your 'must have' tools and apps?
Jun 23, 2014 @ 12:54:45

If you're a PHP developer and are looking for some new tools to "up your game" and improve your development life, check out this new post to /r/php on Reddit.com. Developers of all kinds have shared tools they've found useful in their own development (and maybe you can too).

In other words, what tools make your development life easier and why? Can be anything from database design to FTP clients to workflow planners. Which tools can you just not live without?

Among the many tools on the list are things like:

  • PHP CodeSniffer
  • PHPUnit
  • IDEs like PHPStorm, Netbeans and editors like Sublime Text
  • Git
  • Composer
  • Vagrant/VirtualBox
  • Xdebug
  • Redis
  • Behat

Check out the full post for the complete (and growing) list.

tagged: musthave tools applications opinion reddit

Link: http://www.reddit.com/r/PHP/comments/28r11n/php_devs_what_are_your_must_have_tools_and_apps/

Reddit.com:
I want a job as a developer. Here's my situation, can you help?
Jun 20, 2013 @ 11:17:48

On Reddit.com there's a recent post asking what kinds of things someone can do to gain the skills they need to get a job as a web developer. Disregard the comment at the top and get straight to the good stuff - there's lots of great recommendations here including:

  • "take the time to take algorithm classes , UML classes and db modelling classes and , very important , read other people's code"
  • "Work on stuff that interests you." and "Work on stuff that doesn't interest you but solves a problem for someone else"
  • "Pick a major CMS (doesn't matter which one) and tear it apart."
  • "Go through the PHP tracks on codeacademy.com"
  • "Go to MIT Open Courseware and start reading up data structures and algorithms."
  • "Just keep programming. You'll do stupid things, but having to do those things should become annoying."

Unfortunately, the poster started things out with a "don't tell me to read a book" mentality, so there's some responses in there about that. Don't let that disuade you from some of the other answers, especially if you're new to PHP, though.

tagged: developer learn advice resource reddit community feedback

Link: http://www.reddit.com/r/PHP/comments/1gpmr5/i_want_a_job_as_a_developer_heres_my_situation

Reddit.com:
Where do people put good PHP job ads now?
Jun 14, 2013 @ 11:08:46

On Reddit.com there's a post sharing some opinions on where to look for PHP jobs and find "the good ones" out of the sea of positions.

I don't want to make this a "hire me" post, because that would and should get downvoted, but where would a person go to find interesting PHP related job ads in 2013? Some of the older big job sites like Monster and Dice are a barren wasteland of boring recruiters hiring for defense contractors, health insurance companies and low end agencies. Github has a small but decent section. Stack Overflow has some decent ones. Hacker news has a monthly thread, but a strong anti-PHP hipster bias. Reddit, at least from search has so few that I find 2 year old ones.

The responses range from links to specific companies looking for people out to some more general resources like LinkedIn, Craigslist, and yes, even recruiters (just be sure to pick a good one).

tagged: position posting jobs opinion reddit

Link: http://www.reddit.com/r/PHP/comments/1g59kb/where_do_people_put_good_php_job_ads_now

Anthony Ferrara:
Failure Is Always An Option - Programming With Anthony
Apr 01, 2013 @ 09:03:19

Anthony Ferrara has posted another video in his "Programming with Anthony" series, this time pointing out that failure is always an option.

A few days ago, I posted a video about how to become a better developer. There were a few interesting comments made, but one in particular from the Reddit threadpeaked my interest. So I decided to do a reply.

You can watch the video either in his blog or over on Youtube. He's also included the some of the contents of the Reddit post and a funny (relevant) comic about learning "C++ in 21 days".

tagged: failure option video programming youtube reddit

Link: