<?xml version="1.0"?>
<rss version="2.0">
  <channel>
    <title>PHPDeveloper.org</title>
    <link>http://www.phpdeveloper.org</link>
    <description>Up-to-the Minute PHP News, views and community</description>
    <language>en-us</language>
    <pubDate>Wed, 19 Jun 2013 23:02:31 -0500</pubDate>
    <ttl>30</ttl>
    <item>
      <title><![CDATA[Vance Lucas: Introducing Bullet: The Functional PHP Micro-Framework]]></title>
      <guid>http://www.phpdeveloper.org/news/18931</guid>
      <link>http://www.phpdeveloper.org/news/18931</link>
      <description><![CDATA[<p>
<i>Vance Lucas</i> has a new post to his site <a href="http://www.vancelucas.com/blog/introducing-bullet-the-functional-php-micro-framework/">sharing at a project</a> he's been working on, a micro-framework for PHP that takes a functional approach to its structure (and the structure of the apps you can make with it), <a href="http://bulletphp.com/">Bullet</a>.
</p>
<blockquote>
<a href="http://bulletphp.com/">Bullet</a> is a new PHP micro-framework with a unique functional approach to URL routing that allows for more flexibility and requires less verbosity than the more typical full route+callback approach found in other micro-frameworks. The main problem with most micro-frameworks and even full-stack MVC frameworks that leads to code duplication is that the callback or method executed to perform the action and respond to the URL route lives fully within its own scope. This means that you are forced to repeat a lot of setup code across URL route handlers that load the same resource, authorize it, etc.
</blockquote>
<p>
He illustrates with an example of a GET/DELETE to the same routes and having to create multiple handlers for each. He restructures this with Bullet and shows how it can nest callbacks inside of handlers to make for simpler routing. It also scopes down requests and gets more fine grained as you nest, making it easier to create reusable handlers (like in other files). If you're interested in finding out more about Bullet and its structure, you can find it in <a href="http://bulletphp.com/">the project's main site</a>.
</p>]]></description>
      <pubDate>Fri, 21 Dec 2012 09:02:00 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Community News: Privates - Harmful or Useful? (Discussion)]]></title>
      <guid>http://www.phpdeveloper.org/news/18878</guid>
      <link>http://www.phpdeveloper.org/news/18878</link>
      <description><![CDATA[<p>
There's been a few articles posted on various blogs in the PHP community recently about the "most correct" usage of the "private" scope in your PHP applications. As with any feature of just about any language out there, there's people on both sides of the fence. Here's the ones that have weighed in so far:
</p>
<ul>
<li><i>Brandon Savage</i>'s <a href="http://www.brandonsavage.net/private-methods-considered-harmful/">initial post</a> (an excerpt from his upcoming "Do This, Not That" book)
<li>A <a href="http://blog.ircmaxell.com/2012/12/response-private-methods-considered.html">response to this</a> from <i>Anthony Ferrara</i>
<li><i>Brandon</I>'s <a href="http://www.brandonsavage.net/in-further-defense-of-avoiding-private-methods/">own response</a> to comments on his previous article
<li><a href="http://www.garfieldtech.com/blog/private-composition-inheritance">This new post</a> from <i>Larry Garfield</i> and some of his experience from the Drupal world
</ul>
<p>
Various topics come up during these posts including static coupling, using interfaces versus inheritance, wrapper classes and developer intent.
</p>]]></description>
      <pubDate>Wed, 12 Dec 2012 09:53:57 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Rob Allen's Blog: Access view variables in another view model]]></title>
      <guid>http://www.phpdeveloper.org/news/17770</guid>
      <link>http://www.phpdeveloper.org/news/17770</link>
      <description><![CDATA[<p>
In <a href="http://akrabat.com/zend-framework-2/access-view-variables-in-another-view-model/">this new post</a> to his blog <i>Rob Allen</i> shows you how to access the view variables from another ViewModel.
</p>
<blockquote>
Unlike Zend Framework 1, the view layer in Zend Framework 2 separates the variables assigned to each view model. This means that when you are in the layout view script, you don't automatically have access to variables that were assigned the the action's view model and vice versa.
</blockquote>
<p>
He includes snippets of code with an example controller and a sample view that fetches a value from a child ViewModel instance. He also shows how to access layout and configuration values in the view.
</p>]]></description>
      <pubDate>Tue, 03 Apr 2012 12:53:37 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Vance Lucas' Blog: Protected vs Private Scope: Arrogance, Fear and Handcuffs]]></title>
      <guid>http://www.phpdeveloper.org/news/16148</guid>
      <link>http://www.phpdeveloper.org/news/16148</link>
      <description><![CDATA[<p>
<i>Vance Lucas</i> has tossed his hat into the ring in the debate about private versus protected scope in PHP projects with <a href="http://www.vancelucas.com/blog/protected-vs-private-scope-arrogance-fear-and-handcuffs/">this new post</a> to his blog.
</p>
<blockquote>
The age old private vs protected debate has been re-ignited in the PHP community recently following the decision of Doctrine2 and Symfony2 to make all class methods private until there is a very clear and proven reason to change them to protected or public. The intention is a good one - to ensure they are providing a clear and stable API through intentional and known extension points that they can better test and support. [...] The problem is that this kind of thinking is a slippery slope that kills the spirit of programming.
</blockquote>
<p>
He suggests that, by limiting the scoping down to private, you're taking away the very thing that gets most people excited about third-party tools - the extensibility. In his opinion, it sends a strong message to other developers that they're "not welcome" to make suggestions or updates to the application/tool. 
</p>]]></description>
      <pubDate>Tue, 05 Apr 2011 10:45:53 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Community News: Dutch PHP Conference - Updates to the site and the schedule]]></title>
      <guid>http://www.phpdeveloper.org/news/15959</guid>
      <link>http://www.phpdeveloper.org/news/15959</link>
      <description><![CDATA[<p>
The Dutch PHP Conference has <a href="http://www.phpconference.nl/home/updates-to-the-site-and-the-schedule/">posted an update</a> about the conference today including changes to the schedule and how its represented on the site.
</p>
<blockquote>
t has been about two weeks since the schedule was published and ticket sales started, but that doesn't mean we haven't done anything in the meantime! There have been a number of updates on both the site and the schedule.
</blockquote>
<p>
There's five new talks that've been added to the schedule including <i>Paul Matthews</i>' presentation on Solr, <i>Chris Jones</i> talking about high performance PHP apps and <i>David Soria Parra</i> on git. The site updates mainly revolve around the classification of the different sessions - icons added to show skill level and scope of the presentation. There's also an update about the unconfernece and official conference social.
</p>]]></description>
      <pubDate>Thu, 24 Feb 2011 13:49:39 -0600</pubDate>
    </item>
    <item>
      <title><![CDATA[Stefan Koopmanschap's Blog: My privates are not public, they are protected ]]></title>
      <guid>http://www.phpdeveloper.org/news/14814</guid>
      <link>http://www.phpdeveloper.org/news/14814</link>
      <description><![CDATA[<p>
<i>Stefan Koopmanschap</i> has <a href="http://www.leftontheweb.com/message/My_privates_are_not_public_they_are_protected">spoken up in response</a> to some of the comments about OOP design, specifically in using the private scope in your applications. Overall, <i>Stefan</i> agrees and thinks that this access prevents possible extension which goes against the whole point of writing open source software.
</p>
<blockquote>
I agree with pro-private people that it is important to have a good API design and to use that to protect less experienced developers from making mistakes, however one should never assume that the developers using your libraries, especially Open Source libraries, are less than yourself. [...] I definitely am not in favor of simply opening up the complete library to every developer though. By making a clear decision on which methods are public and which methods are protected you will ensure that people simply implementing your library will use the API that you have taken the time designing.
</blockquote>
<p>
His <a href="http://www.leftontheweb.com/message/My_privates_are_not_public_they_are_protected">does note</a>, however, that there are cases when a private scope is valid - usually when it involves a planned, architected product where it is someone's responsibility to have that access controlled.
</p>]]></description>
      <pubDate>Mon, 19 Jul 2010 13:58:12 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Ivo Jansch's Blog: Good use of public, private and protected in OO class design]]></title>
      <guid>http://www.phpdeveloper.org/news/14811</guid>
      <link>http://www.phpdeveloper.org/news/14811</link>
      <description><![CDATA[<p>
In a new post to his blog <i>Ivo Jansch</i> responds to some of the recent comments about scoping in PHP applications with some <a href="http://www.jansch.nl/2010/07/19/good-use-of-public-private-and-protected-in-oo-class-design/">thoughts of his own</a> (someone spurred on by the <a href="http://symfony-project.org">Symfony</a> project saying that "private is evil").
</p>
<blockquote>
I don't care much about Symfony as I'm not a user, but it turned to a discussion on OO theory when Stefan <A href="http://www.leftontheweb.com/message/My_privates_are_not_public_they_are_protected">defended the position</a> by claiming that you 'should have the right to extend a class's methods if it doesn't support the use case you have'.
</blockquote>
<p>
He also mentions the agreeing opinions of <a href="http://twitter.com/mtabini/status/18867470296">Marco Tabini</a> and <a href="http://twitter.com/tswicegood/status/18864493405">Travis Swicegood</a>. <i>Ivo</i> gives an example of a piece of code that uses all three states - public, protected and private - as a use case for his later statements. In his opinion, removing the private/protected scoping from the picture only helps those looking to make it easier to derive information from the class rather than fine-tuning what can be called.
</p>
<p>
Be sure to <a href="http://www.jansch.nl/2010/07/19/good-use-of-public-private-and-protected-in-oo-class-design/#comments">read the comments</a> on this one - there's lots of great thoughts from community members in there.
</p>]]></description>
      <pubDate>Mon, 19 Jul 2010 10:57:14 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[DevShed: PHP 5 Helpers: Calling Methods Out of Object Scope]]></title>
      <guid>http://www.phpdeveloper.org/news/12946</guid>
      <link>http://www.phpdeveloper.org/news/12946</link>
      <description><![CDATA[<p>
In <a href="http://www.devshed.com/c/a/PHP/PHP-5-Helpers-Calling-Methods-Out-of-Object-Scope">this new tutorial</a> from DevShed today they continue their series looking at making helper classes for your applications. This time they're focusing on using methods without needing to create an object first - static methods.
</p>
<blockquote>
The methods of the class that I [just] mentioned were declared implicitly dynamic, even though it's perfectly possible to call them statically, and the PHP engine won't raise any errors about this process. However, it would be much better to declare these methods explicitly static, thus taking advantage of the functionality offered by the text helper class without having to spawn an instance of it.
</blockquote>
<p>
They show how to <a href="http://www.devshed.com/c/a/PHP/PHP-5-Helpers-Calling-Methods-Out-of-Object-Scope/2/">define the methods</a> with the "static" keyword so they can be called outside of the class' scope. Code for the helper class and the code to put it to use.
</p>]]></description>
      <pubDate>Mon, 27 Jul 2009 12:38:17 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Zend Developer Zone: ZendCon 2009 Call for Papers is now open!]]></title>
      <guid>http://www.phpdeveloper.org/news/12453</guid>
      <link>http://www.phpdeveloper.org/news/12453</link>
      <description><![CDATA[<p>
The Zend Developer Zend has <a href="http://devzone.zend.com/article/4558-ZendCon-2009-Call-for-Papers-is-now-open">posted the announcement</a> that the Call for Papers for this year's <a href="http://zendcon.com">ZendCon - The PHP Conference</a> has been opened.
</p> 
<blockquote>
Welcome to the <a href="http://zendcon.com/">Call for Papers</a> for the 2009 edition of <a href="http://zendcon.com/">ZendCon '" The PHP Conference</a>. This year's conference will be held October 19th '" 22nd at the San Jose Convention Center and is being co-presented by S&S Media. It is the largest gathering of the PHP Community and the premier PHP conference, allowing all attendees to mingle with decision makers, core developers, prominent community members, and so many more.
</blockquote>
<p>
The scope of this year's conference has widened a bit and won't just be about PHP-related topics. Proposals for sessions about things like project lifecycle, frameworks, and performance tuning will also be accepted. There will be five different tracks this year:
</p>
<ul>
<li>Server/Operations
<li>Lifecycle Best Practices
<li>Frameworks
<li>Real World PHP
<li>PHP Development Topics
</ul>
<p>
The Call for Papers ends May 31st, so get over and <a href="http://zendcon.com/">submit your proposal</a> before time runs out!
</p>]]></description>
      <pubDate>Tue, 05 May 2009 07:50:49 -0500</pubDate>
    </item>
    <item>
      <title><![CDATA[Leonid Mamchenkov's Blog: Perl vs. PHP : variable scoping]]></title>
      <guid>http://www.phpdeveloper.org/news/11559</guid>
      <link>http://www.phpdeveloper.org/news/11559</link>
      <description><![CDATA[<p>
<i>Leonid Mamchenkov</i> has compared Perl versus PHP in <a href="http://mamchenkov.net/wordpress/2008/12/12/perl-vs-php-variable-scoping/">this new blog post</a> - specifically how they handle variable scoping.
</p>
<blockquote>
I've mentioned quite a few times that I am a big fan of Perl programming language.  However, most of my programming time these days is spent in PHP.  The languages are often similar, with PHP having its roots in Perl, and Perl being such a influence in the world of programming languages.  This similarity is often very helpful.  However there are a few difference, some of which are obvious and others are not.
</blockquote>
<p>
His example compares looping (a foreach in both) and how, after the Perl loop the $value variable is no longer accessible. In PHP, however, it's passed back out into the current scope and can be read just like any other variable. While this can be useful, it can also cause headaches when trying to track down elusive bugs.
</p>]]></description>
      <pubDate>Fri, 12 Dec 2008 08:49:14 -0600</pubDate>
    </item>
  </channel>
</rss>
