PHPDeveloper.orghttp://www.phpdeveloper.org
Up-to-the Minute PHP News, views and communityen-usTue, 31 Mar 2015 15:48:07 -050030http://www.phpdeveloper.org/news/22524http://www.phpdeveloper.org/news/22524
The ServerGrove blog has a new post today introducing the new Symfony Installer, a tool that can make getting started with a Symfony2 application quick and easy.

Yesterday, the Symfony team introduced the new Symfony installer. Its main goal is to help developers to create Symfony projects faster. Until now, installing Symfony to start a new project required a few steps. [...] The installer tries to do this in one step. It downloads a compressed file with all the code, including the vendors directory, so you don't need anything else to run Symfony for the first time.

The post shows you how to install the installer via a curl call to fetch the executable. They show how to use it to create a new project, making a demo project and the resulting application and web interface for the demo. They also mention some of the future work that's planned for the installer including HTTPS support and caching improvements. The post finishes up with a quick mention of the code "under the hood" using the Symfony console component.

Link: http://blog.servergrove.com/2015/03/27/new-symfony-installer-fastest-way-start-symfony-project/]]>Fri, 27 Mar 2015 12:13:42 -0500http://www.phpdeveloper.org/news/22018http://www.phpdeveloper.org/news/22018
The SitePoint PHP blog has a new post from Lukas White that gets into the details of combining SOLR searching with Solarium to perform geospatial queries.

In a recent series of articles I looked in detail at Apache's SOLR and Solarium. To recap; SOLR is a search service with a raft of features - such as faceted search and result highlighting - which runs as a web service. Solarium is a PHP library which allows you to integrate with SOLR - whether local or remote - interacting with it as if it were a native component of your application. If you're unfamiliar with either, then my series is over here, and I'd urge you to take a look. In this article, I'm going to look at another part of SOLR which warrants its own discussion; Geospatial search.

He uses a simple example, locating airports near a given location, to give a more "real world" idea of how it all works. He starts by introducing the concept of geospatial searching and the idea of "points" as they relate to a specific location. He then gets into the actual setup of the application, including the SOLR schema configuration and making the queries on the data. The Solarium library allows for simple location queries when given just the "latlong" helper type and the location/distance to use for the starting point. He uses the data from the OpenFlights service to gather the airport data and creates a search form and basic list output of the results from searches on it. If you'd like to see the end result in action, check out this demo website.

Link: http://www.sitepoint.com/geospatial-search-solr-solarium/]]>Tue, 25 Nov 2014 13:55:56 -0600http://www.phpdeveloper.org/news/21807http://www.phpdeveloper.org/news/21807
The SitePoint PHP blog has posted the second part of their series about using the CoinBase API through PHP. In this new tutorial they use the API connection made in the first part via the Coinbase SDK.

In part 1, we covered basic installation and usage of Coinbase's Bitcoin PHP API and the accompanying SDK. In this second and final part, we'll be building our sample application.

He briefly shows how to send and receive bitcoins before diving into the application. His simple application includes a basic welcome page, a payment page, thanks page and a cancel page (in case of errors). Complete code for the HTML, CSS, and PHP (API calls) is included in the post. He shows how to create the button to start the payment process and add it to the page.

Link: http://www.sitepoint.com/bitcoin-php-coinbases-api-demo-app/]]>Thu, 09 Oct 2014 09:25:51 -0500http://www.phpdeveloper.org/news/21613http://www.phpdeveloper.org/news/21613
The Qandidate blog has a new post today that "pulls back the curtain" as to how they manage their development process and get their work done.

At Qandidate.com we tried a lot of different project management tools and techniques. After two years of experimenting I want to share our current process, seen from my role as product owner (PO). One reason for sharing this, is to help you improve your process, but the most important reason is to start a discussion with you based on your experience, to improve our process even more. Our main rule at Qandidate.com is to embrace change. Always be open for changes that may or may not improve your process. If a change improves the process it's a win. If you didn't try it you will never know!

They walk through the three main points over the overall flow of work there:

The process itself including two week sprints containing (unestimated) stories

A demo and stakeholders meeting showing the work they've done during the sprint and get feedback from the stakeholders

The stories and how they're created and when/how new ones are added (their "piano meetings").

They also include testing, both frontend and backend, and focus on small chunks of functionality instead of quick and dirty hacks. While their process won't work for every group (and is more of a "scrum-but..." setup) it is interesting to see how another group does their work.

Link: http://labs.qandidate.com/blog/2014/08/21/development-process-at-qandidate-com/]]>Fri, 22 Aug 2014 10:34:46 -0500http://www.phpdeveloper.org/news/21565http://www.phpdeveloper.org/news/21565
On the Qandidate.com blog there's a new post looking at fault tolerant programming in PHP, a follow up to their previous post introducing the topic and creating a "circuit breaker" to prevent major issues when a problem pops up.

Now we will show you a running demo of the application where the circuit breaker library Phystrix is combined with asynchronous programming. The advantage of this approach is that it allows the querying of multiple backend services asynchronously. A timeout can be set for each of the calls and the circuit breaker will deal with failing services.

A screencast included in the post shows a script in action and how it reacts when the various services it needs fail. They've posted the code for the demo can be found over on GitHub and full instructions to run it are included in the post. Also included is some of the output from the test and a peek inside the logs showing where things were broken and if they were able to recover.

Link: http://labs.qandidate.com/blog/2014/08/11/asynchronous-fault-tolerant-programming-in-php/]]>Tue, 12 Aug 2014 12:17:20 -0500http://www.phpdeveloper.org/news/21059http://www.phpdeveloper.org/news/21059
If you're relatively new to using the Symfony2 framework, you might be wondering about some of the things happening during requests to your application. One of these things is the routing and handling of each request. In this new post from NetTuts.com they introduce you to the foundations of Symfony2 routing in a screencast.

In the last video, I said we'd take a look at controllers next, but I actually feel it may be easier to learn the framework in a slightly different order. Instead, we're going to learn about the basics of Symfony 2 routing, to give our applications clean and pretty URLs and make it easy to manage our applications URLs and links. We're not going to get too detailed, as Symfony's routing can do quite a bit, but we'll at least cover what we need to know by keeping it straight and to the point.

The screencast is a bit less than 10 minutes long and provides an overview of the routing, how it interacts with bundles and controllers. There's also a bit about using annotations to help define routing information directly in the controller.

Link: http://code.tutsplus.com/tutorials/routing-overview-basics-in-symfony-2--cms-20754]]>Thu, 17 Apr 2014 12:10:12 -0500http://www.phpdeveloper.org/news/20277http://www.phpdeveloper.org/news/20277
Mikko Koppanen has written up a quick post sharing some work he's done to help make writing extension in PHP a little bit easier. He's created a new project that shares some of his experience in extension development.

I plan to add practical examples related to extension writing. There won't be extensive written documentation outside the code, but hopefully the code itself contains enough nuggets of information to be useful. As the README says, if you need a specific example or clarification on something just open an issue in Github.

The project is still in its early stages, but plans are to have quite a bit more examples as time goes on. Also, as Johannes Schlüter points out in the comments, there's also another example like this - Marcus Boerger's demoext (with accompanying slides).

Link: http://valokuva.org/php-extension-writing/]]>Mon, 21 Oct 2013 10:35:15 -0500http://www.phpdeveloper.org/news/18917http://www.phpdeveloper.org/news/18917
The Aura framework project has released a set of updates to several of their packages including the main Aura.Framework and Aura.Demo functionality.

Late last night we released version 1.0.0-beta4 of the full-stack system, which composes all the independent Aura packages into a coherent framework using the Aura.Framework package in a project skeleton. We have extracted the "hello world" portions into their own Aura.Demo package so that it can be removed or disabled when you begin your project. Download it and take it for a spin!

There's been a lot of talk recently about the Aura framework and its "less dependencies, more separate packages" approach to making the framework including thesepostsfromPaul Jones and others.

]]>Wed, 19 Dec 2012 11:06:02 -0600http://www.phpdeveloper.org/news/18088http://www.phpdeveloper.org/news/18088
On the WebSpeaks.in site, there's a recent tutorial posted showing how you can extract the contents of a zip file from inside a PHP application.

Sometimes you may want the users on your site to upload the zip file and then check what are the contents of that zip file. In this article I will tell you how to extract the contents of the zip file. I temporarily extract the zip files to a directory and then delete it afterwards. You can chose to keep the extracted content if you want.

The tutorial walks you through the code, showing you how to use their "ZipArchive" class to grab the file, extract the contents and display a list of the "child files" inside it. You can see a live demo of it in action or just download the source and dive right in.

]]>Wed, 13 Jun 2012 10:44:44 -0500http://www.phpdeveloper.org/news/18034http://www.phpdeveloper.org/news/18034
In this new tutorial to the WebSpeaks blog, Arvind Bhardwj shows you how to hook up to the Google+ API and search profiles for your desired terms.

The main aim of this application is to go familiar with the Google Plus API usage. Google Plus provides an extremely easy to use API to access the public contents on it. Here we will create a simple search application to search user profiles on Google Plus.

Complete code is provided in the post (PHP) and instructions on setting up an "application" on G+ so you can get the keys needed to connect to the API. You can see it in action in the live demo or just download the source to get started.