During ZendCon this year, we released 2.0.0beta1 of Zend Framework.
The key story in the release is the creation of a new MVC layer, and to sweeten
the story, the addition of a modular application architecture.
"Modular? What's that mean?" For ZF2, "modular" means that your application is
built of one or more "modules". In a lexicon agreed upon during our IRC
meetings, a module is a collection of code and other files that solves a
specific atomic problem of the application or website.
On PHPMaster.com today they share a list of helpful tools and tricks that you can apply not only to your PHP development, but programming in general. They highlight code templates, using hotkeys and Ditto.There are also other helpful pieces of software such as libraries, code snippets, and third party applications. In this article I'll show you how I use a feature built into NetBeans along with two other applications to increase my productivity when programming on Windows. These tips and techniques offer...
Ed Finkler has a new post today showing how he's created a tumbleblog using the Gimmie Bar API and backend as a source for the posts. For the curious, the code for his simple blog can be found here.One of the coolest things about working on Gimme Bar has been the opportunity to build a platform. While most folks interact with our service via the web site, the site is just one application built on top of the Gimme Bar content collection and curation system. Our web site interacts with the system via our...
Derick Rethans has a new post today looking at a method for setting up multiple PHP versions on the same machine and switch between them with a little help from some simple bash scripts.For many of my projects (both hobby and commercial) I need to support many different PHP configurations. Not only just different PHP versions, but also debug builds, ZTS builds and 32-bit builds. In order to be able to test and build extensions against all those different PHP configurations I have adopted a simple method...
In this new post to his blog Davey Shafik looks at an alternative to the traditional arrays most scripts use - something a little faster and more specific: SplFixedArray, part of the Standard PHP Library included with every release.The SplFixedArray class provides a super-fast, fixed size array implementation. There are some limitations however, first you must use numeric keys and secondly you cannot use anonymous assignment (i.e. $array = 'value';). You'll notice one requirement was missing, that it...
Latest PEAR Releases:
Arrays, long considered the work horse of PHP have one flaw: they can be incredibly slow. There is however an alternative -A at least, for a small subset of use cases. SplFixedArray.
You use SplFixedArray like so:
The SplFixedArray class provides a super-fast, fixed size array implementation. There are some limitations however, first you must use numeric keys and secondly you cannot use anonymous assignment (i.e. $array = 'value';).
You'll notice one requirement was missing, that it should have a...
The series Using X with PHP mysqli continues. After notes on calling stored procedures and using prepared statements, its time for a multiple statement quickstart. A mighty tool, if used with carea€¦
Using Multiple Statements with mysqli
MySQL optionally allows having multiple statements in one statement string. Sending multiple statements at once reduces client-server round trips but requires special handling.
Multiple statements or multi queries must be executed with mysqli_multi_query(). The...
Multiple PHP versions set-up
Monday, November 7th 2011, 09:11 GMT
For many of my projects (both hobby and commercial) I need to support many different PHP configurations. Not only just different PHP versions, but also debug builds, ZTS builds and 32-bit builds. In order to be able to test and build extensions against all those different PHP configurations I have adopted a simple method that I'm sharing with you here.
The major part of it is that I use a different installation prefix for...
I noticed that archivers/pecl-phar vanished from the ports tree on one of my FreeBSD servers.
Problem?Reasons to remove the port were:
the port is unmaintained
the port was based on the outdated phar extension from pecl
phar (in pecl) contains open security issues
The simple solution is to create a new port which of course will use the phar which is bundled in PHP's core. And I will get to that (but feel free to beat me at it ;-)).SolutionIn the meantime, here's a simple solution to get phar on...
Like many other projects, many components of PEAR have started a migration to github.
We have two primary organisations set up for PEAR and PEAR2.
While the existing PEAR packages will continue to use the pear.php.net distribution and bug tracking capabilities; it's never been easier to contribute to a PEAR package - simply fork; add your changes and send us a pull request.
If your preferred packages aren't yet on github, please feel free to drop us a line on the pear-dev mailing list.
One of the coolest things about working on Gimme Bar has been the opportunity to build a platform. While most folks interact with our service via the web site, the site is just one application built on top of the Gimme Bar content collection and curation system. Our web site interacts with the system via our HTTP API, which is open to everyone, not just our internal team. That means that anyone can build applications on top of our platform to suit their own needs or interests.To demonstrate this, I...
PECL/mysqlnd 1.1.2-stable has been released. The mysqlnd replication and load balancing plugin for PHP 5.3/5.4 finally got the download label it deserves: stable, ready for production use! PECL/mysqlnd_ms makes using any kind of MySQL database cluster easier.
Download PECL/mysqlnd from pecl.php.net
Documentation at the PHP Reference Manual
The release motto of the 1.1 series is a€ocover MySQL Replication basics with production qualitya€¯, which shows that the plugin is optimized for...
Kevin Schroeder has a quick tip for anyone using phpcloud.com and having trouble with git and "remote end hung up" error messages.If you are using phpcloud.com and are experiencing errors with git [...] and you are trying to push large files (not sure what is defined as "large") you may need to change some git settings.He points out two settings - one for Windows and the other for Linux - that increase the buffer size to handle larger files that might be included in your repository.
Ulf Wendel has a new post today with details on using stored procedures with mysqli - not overly difficult if you know how to handle the IN, OUT and INOUT parameters. He includes a few code examples showing how to use them.Out of curiosity I asked another friend, a team lead, how things where going with their PHP MySQL project, for which they had planned to have most of their business logic in stored procedures. I got an email in reply stating something along the lines: "Our developers found that mysqli...
On DZone.com Giorgio Sironi has a new post talking about a development practice that's becoming more and more popular (rather than the old standby of one development platform for all developers) - using virtual machines as reusable, easily renewable platforms. He talks about the process he went through to set up PHP, including the commands used during the process.This is an occasion to learn about a virtualization tool which I'm not familiar with, VirtualBox. The goal is to install PHP 5.4, which is not...
PHPUnit is one of the most widely used unit testing tools for PHP applications. It comes packed with features, some that are commonly used and some not so much. In a new post to his blog today Volker Dusch looks at one specific feature - the "@covers" annotation you can use in your tests' comments to specify which functionality you're actually testing.One of the goals of your test suite and the coverage report is to make you trust in your code base and to remove the fear of changing something that needs...
Starting with PHP mysqli is easy, if one has some SQL and PHP skills. To get started one needs to know about the specifics of MySQL and a few code snippets. Using MySQL stored procedures with PHP mysqli has found enough readers to begin with a a€oquickstarta€¯ or a€ohow-toa€¯ series. Take this post with a grain of salt. I have nothing against Prepared Statements as such, but I dislike unreflected blind use.
Using prepared statements with mysqli
The MySQL database supports prepared statements. A...
In a new post to his blog today Anthony Ferrara looks at the (heated) discussion that's popped up around having the PSR-0 autoloader standard included as a part of the PHP core. He gives his reasons (three of them) why he's not for the decision.Recently there has been a rather heated and intense discussion on whether the PSR-0 autoloader "standard" should be included as part of the PHP core (in ext/spl to be exact). I've tried to stay out of the discussion and have successfully done so. Until today. I...
Popular posts from PHPDeveloper.org for the past week:Johannes Schmitt's Blog: A New Killer Feature for Symfony2 Security
XpertDeveloper.com: Abstract in PHP
Community News: ZendCon 2011 Wrap-ups (from a Speaker & Zend)
DZone.com: Closure Object Binding in PHP 5.4
Developer Drive: Create Your Own CRUD App with MySQL and PHP
PHPBuilder.com: An Early Look at Zend Framework 2.0
ArsMagnaTutorials: FuelPHP Tutorial Videos
Ibuildings techPortal: Architecture Patterns: Domain Model and Friends