SitePoint PHPPHP News You May Have Missed – October / November 2014 (26.11.2014, 17:00 UTC)

In an already all too familiar format, here’s more PHP news you may have missed over the past month or so. Some of these will be presented in more depth in future posts, but it’s just as important to have a heads up about them. HHVM HHVM is on fire lately – we have four […]

Continue reading %PHP News You May Have Missed – October / November 2014%

Symfony CMFSymfony CMF Hackdays in Würzburg (12/13 Dec. 2014) (26.11.2014, 05:00 UTC)

The Mayflower Gmbh will host the next Symfony CMF Hackday in Würzburg, Germany. It will be focused on the roadmap for the 1.3 release. We are going to have nearly two days of hacking and pushing the CMF forward to the next version.

You can sign up to the event on Doodle. There will be a public workshop as an opener, too. You can get more information via the Facebook-Event. This workshop is public, but limited to 8 persons.

Both events are located at:

Mayflower GmbH
Gneisenaustraße 10/11
97074 Würzburg

PHP ClassesOAuth Pin Based Authorization for Twitter, LinkedIn, Imgur and Others (25.11.2014, 10:13 UTC)
By Manuel Lemos
Some applications need to access OAuth based APIs but since they are not based on regular Web browsers, they need to need to use an alternative method to obtain the user authorization.

Pin based authorization is a method used for instance by applications based on the command line, desktop applications, embedded systems, game consoles, and certain types of mobile apps.

Read this article to learn how the pin based OAuth authorization process works and how can you implement it in your applications using the PHP OAuth API class.
Derick RethansLondon in Fives: The Making Of (25.11.2014, 08:55 UTC)

London in Fives: The Making Of

A few days ago I published a video called "London in Fives" on Vimeo. In this article I am explaining how I made this, including the hardware and software that I used.

But first, let's have a look at the video itself:

London in Fives

There are 25 sections in this video, each taking 5 seconds. Because the frame rate is 25 fps, that means there are 125 frames per segment. All those numbers are powers of 5, hence the title of the film: London in Fives.

The first and last segments are merely the title and end credits, and are just a series of images. The more interesting bits are the 23 segments in between.


All these segments are made from single frame shots from my Nikon D300 DSLR camera. It has a feature that allows a picture to be taken every 5 seconds automatically. For all segments, except for the night time shot of Covent Garden and the Ice Skating, that created the raw images.

For each segment, I usually took a few more shots than the 125 required, usually up to a 150, to have a bit of a choice of where to start and end the segment. In one case (the Regent's Park sunrise in the fog segment), I was happy that I did! Due to a hard drive failure I fortunately managed to only lose a few images, so that I still had just 125 left!

Of course it is important to keep the camera steady between all of the shots. In most of the segments I used a GorillaPod, a three legged flexible tripod where each leg can wrap around objects. In the later scenes, I used a normal stand-up tripod, a Manfrotto befree.


The camera movements are all done in post production, except for the night time shot of Covent Garden and the Ice Skating segments. Instead of using my camera's "take a photo every x seconds" feature, I relied on hardware to take both a photo every 5 seconds, but also rotate the camera slightly on top of its tripod. The time lapsing device that I used to rotate and instruct the camera to take a photo every 5 seconds is an Astro. This is a disk like device that can rotate around one axis and instruct the camera through a cable to take a photo at specific intervals over a certain period of time. I think that for future time lapses I will not rotate more than 30° for a 125 segment shoot as otherwise it goes a bit too fast.

To make sure I had my camera perfectly horizontal on my camera, I used a spirit level that sits on top of my flash socket.

Post Processing

After taking the photos, some post-processing was necessary. There are three types of post-processing that I had to do, depending on how the photos were shot.

For the two segments created with the Astro, I really only had to rescale the photos from the camera's native resolution to 1280x720.

For one other segment (Regent's Park sunrise in the fog), the GorillaPod was sitting on a bench that didn't turn out to be stable enough and lots of instability was introduced among the different images. I used Hugin's align_image_stack tool to align them in such a way they formed a stable sequence of images. This tool is usually used to "align overlapping images for HDR creation", but it also suited my use case very well. Basically, I ran the following command:

align_image_stack -a aligned/a -v -i -C --threads 3 *jpg

I first also tried enabling GPU support for remapping, but that just ended up crashing the tool. The tool here is called with an output prefix of aligned/a and the -C auto-cropped the image sequence so that it covered an area that all images shared.


Truncated by Planet PHP, read more at the original (another 6655 bytes)

Cal EvansInterview with Lorna Jane Mitchell (25.11.2014, 05:00 UTC) Link
labs @ Qandidate.comBroadway just got a new release (25.11.2014, 00:00 UTC)

Today we tagged version 0.3.0 for Broadway. In this version we have merged some nice pull requests from various contributors, thanks to everybody that submitted issues and/or pull requests!

One of the pull requests we received is from simensen. He added factories for our aggregates.

∞ labs @ Permalink

Horde newsHorde im Tatort (24.11.2014, 18:46 UTC)
Horde Groupware played a role in Germany's number one crime series on Sunday evening.
Anthony FerraraAlternatives To MVC (24.11.2014, 18:00 UTC)
Last week, I wrote A Beginner's Guide To MVC For The Web. In it, I described some of the problems with both the MVC pattern and the conceptual "MVC" that frameworks use. But what I didn't do is describe better ways. I didn't describe any of the alternatives. So let's do that. Let's talk about some of the alternatives to MVC...

Read more »
SitePoint PHPGeospatial Search with SOLR and Solarium (24.11.2014, 17:00 UTC)

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.

An Example

I’ve put together a simple example application to accompany this article. You can get it from Github, or see it in action here.

Before we delve into that, let’s look at some of the background.

Sometimes, the things you want to search for have geographical locations. Often, that provides vital context. It’s all very well me being able to search for “Italian restaurants”, but I’m hungry - a restaurant on another continent, as good as it might be, is of no help. Rather, it would be far more useful to be able to run a search which asks “show me Italian restaurants, but within 5 miles”. Or alternatively, “show me the ten closest Italian restaurants”. That’s where Geospatial search comes in.

Continue reading %Geospatial Search with SOLR and Solarium%

Paul ReinheimerMongo Replicaset Issue - NAT'd server (24.11.2014, 00:19 UTC)

We just ran into an issue joining a new server to our MongoDB replica set powering Where’s it Up & ShotSherpa. We copied the data over to give it a good starting point, then added it to the replica set. We waited a while, it still hadn’t joined, looking at the tail of the log showed many connection lines, nothing telling. When I restarted MongoDB I saw:

replSet info self not present in the repl set configuration

I tried pinging the server’s hostname to ensure it was successful. No problem. I tried connecting to the server using the mongo command line on the primary server (`mongo`). No problem.

Eventually I copied the mongo hostname from the replica set configuration, and tried to use it to connect to mongo on the new secondary. No dice! As it turns out the NAT hadn’t been configured to allow that hostname to work locally. A few new entries in our /etc/hosts file later, and our server was joined successfully.

MongoDB Tip:

When MongoDB has trouble connecting, try the connection strings listed in the replica set config from all relevant hosts.

LinksRSS 0.92   RDF 1.
Atom Feed   100% Popoon
PHP5 powered   PEAR
ButtonsPlanet PHP   Planet PHP
Planet PHP