2012年4月2日星期一
PHPMaster.com: Continuous Integration (with Jenkins), Part 2
Following up from his previous post about setting up PHP with Jenkins, J Armando Jeronymo is back with part two of the series - setting up an example project to show how the pieces fit together.
In the first part of this article I presented the case for Continuous Integration. Now we'll install and set Jenkins up to monitor the automatic building of a simple demonstration PHP application. We'll begin with the demo project, then address Jenkins' installation, and finally set it up and watch it running.
He includes a sample project structure, complete with a PHP class and its tests. He shows how to manually run things first (so you'll know what the commands do), the contents of the class/tests and the example Ant configuration file. He's also included screenshots of the Jenkins interface, showing how to create a build, add a new step and let the build run to evaluate the results.
Design Aeon: Cake PHP Search Component
On the Design Aeon blog there's a new post sharing a CakePHP component that can be used to easily add searching to your framework-based application.
Cake Php Search Component is used to implement search in your cake php projects.The component provide highly reusability. component is meant to use across all the controllers. you just include this search component in your Controller and call a component function to fetch your conditions types in search form and refine the data .
The component (available for download here) is simple to install and full instructions for implementing it are included in the post - including it in the controller, creating search and pagination elements, making a controller action and finally making a view to tie it all together.
7php.com: Interview with Rafael Dohms, The Brazilian PHP Evangelist
On 7php.com there's a new interview with a member of the PHP community - this time it's with Rafael Dohms, formerly of the Brazilian PHP community, he now lives in Amsterdam and is active in the European PHP scene.
In this edition I talked with Rafael Dohms ( @rdohms ), The Brazilian PHP Evangelist. He is to the PHP Community and specially to The Brazilian PHP Community, what Brazilian Ronaldo is to the Football World! He has founded two PHP user-groups and is seen as an AWESOME active member of the PHP Community; he is also an active contributor to some conspicuous open-source PHP projects as you will found out for yourself in this interview. Rafael is very passionate about helping out fellow developers generously; you can read more about him on his personal website/blog.
In his answers, Rafael talks about things like:
- Some of his first experiences with PHP (including a CounterStrike clan website)
- His recommendation of the book "The Art of Readable Code"
- His favorite conference (hint: It's in Chicago each year)
- His recommendation for less arguments in the community
- Thoughts on PHP 5.4 and its features
- Some of his experiences with both starting and being a member of various PHP user groups
You can read the full interview here.
Community News: Web & PHP Magazine Launched!
As of March 30th, the PHP community has a new resource to learn and grow in their favorite language - the Web & PHP Magazine (published by S&S Media).
This is an exciting time for PHP and an exciting time to be launching a new publication. [...] We think we've got a great selection of articles in this first issue of Web & PHP Magazine, and we hope there's something of interest for PHP devs of every skill level. Feel free to get in touch if there's anything that you'd like to see in next month's issue, or submit a piece yourself. As ever, we'll be out and about in the PHP community over the next few months, so don't hesitate to say hello.
In their inaugural issue, there's articles about the PHP UK Conference, Security and emerging databases. There's also an interview with Robert Douglass (Senior Drupal Advisor at Acquia).
They're also offering the issue for download directly from their site (as a PDF) with later issues coming to multiple platforms (like mobile devices).
2012年3月30日星期五
Site News: Popular Posts for the Week of 03.30.2012
- InfoWorld: Review: 2 PHP tools rise above the rest
- Monitor.us Blog: Website Performance: PHP
- Chris Morrell's Blog: Introducing Zit, an object-oriented dependency injection container
- James Fuller's Blog: Enforcing contracts in your PHP functions and methods
- Freek Lijten's Blog: SOLID - The S is for Single responsibility
- Alex Hudson's Blog: A (fond) farewell to Zend Framework
- PHPMaster.com: Continuous Integration (with Jenkins), Part 1
- Site News: Popular Posts for the Week of 03.23.2012
- Cats Who Code: Sending SMS with PHP and TextMagic: An A to Z guide
- Emran Hasan's Blog: Using Mockery as a mocking framework with PHPUnit
Rob Allen's Blog: Returning JSON using the Accept header in ZF2
In a previous post Rob Allen showed how to return JSON data from a controller in a Zend Framework 2 application. In this new post he shows how to use the "Accepts" header from the client to do the same thing.
Following yesterday's article on returning JSON from a ZF2 controller action, Lukas suggested that I should also demonstrate how to use the Accept header to get JSON. So this is how you do it!
You'll need to create the JsonStrategy first, then you can return the ViewModel from the controller. If all goes well, you should see the sample HTML page rendered in a browser and JSON output when requested with the right "Accept" header (he uses curl in his example).