PhpRiot
News Archive
PhpRiot Newsletter
Your Email Address:

More information
Displaying news posts 2781 to 2800 of 6889

Handling SQL Errors in PDO

Handling SQL Errors in PDO
I love PHP's PDO (PHP Data Objects) extension; it gives a consistent, object-oriented interface to handling all kinds of relational database backends. One thing that annoys me is that the MySQL driver for PDO defaults to a silent error mode which can make SQL errors tricky to spot! To give you an example, consider the query below (the correct tablename is country, so this SQL will fail): $db = new PDO('mysql:host=localhost;dbname=sakila', 'user', 'pass'); A $sql = 'select * from countrt'; $stmt =...

php|architect: php|architect Live! presents The Cloud Summit

php|architect: php|architect Live! presents The Cloud Summit
php|architect has officially announced the speaker line up for what they call their "Cloud Summit", a day-long event happening at the end of November about cloud computing - what it is and how you and your PHP applications can take advantage of it.Tired of hearing about the ever-so... nebulous "Cloud" and what vendors say it will do for humankind? Yeah, us too. So, why won't it just go away? We found some folks who have used the cloud successfully to strike it big and asked them to show us why it made...

Community News: PHP UK Conference 2012 - "Blind Bird" Tickets until Dec. 4th

Community News: PHP UK Conference 2012 - "Blind Bird" Tickets until Dec. 4th
As a reminder, the PHP UK Conference (2012) still has their "Blind Bird" tickets on sale until the 4th of December for £90:Purchase blindbird 2012 conference registration(s) for Friday 24th and/or Saturday 25th February - available at this price until 4th December 2011. After this time the earlybird 2012 conference registration for Friday 24th February will be available at £120/£210 excluding VAT, with only the full price of £140/£250 excluding VAT available from 3rd January 2012.The conference is...

Court Ewing's Blog: Follow-up: How PHP is Broken and How It Can Be Fixed

Court Ewing's Blog: Follow-up: How PHP is Broken and How It Can Be Fixed
In a follow up to his previous post about how PHP is broken (and what can be done to fix it), Court Ewing has this new post with a few suggestions on how PHP development could be better, but admits that PHP itself is not broken.It is no secret that the PHP development process has never been a shining example of project organization or quality assurance. Until recently, some of the most important aspects of any project's development cycle were either entirely lacking or were ill-defined. Worse, there was...

php|architect: Full-text Search with SQLite

php|architect: Full-text Search with SQLite
On the php|architect site there's a recent tutorial from Jeremy Kendall about full-text searching in SQLite, a lightweight database alternative that, since it's stored locally, can be used without a full database server.Full-text search with SQLite is so ridiculously easy to implement, there are only two valid reasons you haven't done it yet. The first is you don't need the full-text capability, and the second is you didn't know it could be done.In his method he creates a full-text search table (using...

PHPMaster.com: Getting Started with PHPUnit

PHPMaster.com: Getting Started with PHPUnit
On PHPMaster.com today, there's a new tutorial helping you get started with on of the most popular unit testing frameworks for PHP, PHPUnit. In this new article they help you write your first tests, run them and figure out what to do when they fail.Most people know that testing your websites is a good idea, but after some time testing can become tedious. What if a lot of this testing process could be automated so you don't have to go trough every function manually, time after time, to ensure that it...

Community News: Latest PECL Releases for 11.15.2011

Community News: Latest PECL Releases for 11.15.2011
Latest PECL Releases: APM 1.0.1 cld 0.5.0

Follow-up: How PHP is Broken and How It Can Be Fixed

Follow-up: How PHP is Broken and How It Can Be Fixed
A few weeks ago I wrote an article in which I complained about a few aspects of the PHP development process that I thought were inexcusable and harmful. The article was surprisingly well-received with only a handful of people responding by demeaning me; given the nature of the article, I'd say that is a big win! The generally positive response does not make up for the flaws in the article itself, however. You see, I started out writing the article with the serious intention of making not only an honest...

Learncomputer.com: PHP Profilers Compared (PHP Quick Profiler & XDebug)

Learncomputer.com: PHP Profilers Compared (PHP Quick Profiler & XDebug)
In a recent post from Learncomputer.com, there's a comparison of two PHP profilers - the PHP Quick Profiler and the one included in Xdebug.Whether you are an experienced developer or just getting started it is important to know how to measure the performance of your scripts and applications so that you can learn to make improvements and optimizations to your code. [...] This article compares two of the most popular [profiling] solutions under free license that you can begin using today to profile your...

Robert Basic's Blog: Benchmarking pages behind a login with ab

Robert Basic's Blog: Benchmarking pages behind a login with ab
Robert Basic has a recent post showing you how to use the "cookie jar" functionality included with Apache's "ab" benchmarking tool to get behind your PHP-based login with a simple curl and grep combo.Tonight I decided to relax a bit and what better way of relaxing is there for a geek then to do some bash scripting?! So for fun and no profit I decided to try and benchmark pages with ab, Apache HTTP server benchmarking tool, which are behind a login. Turns out, it's pretty easy after reading some man...

Lukas Smith's Blog: Travis, CI for OSS

Lukas Smith's Blog: Travis, CI for OSS
In a new post to his blog Lukas Smith looks at a recently introduced service, Travis CI that helps make continuous integration simple (and without having to set up the software yourself). He talks about his experiences in getting his trial project up and working with their system.Continuous integration is one of these topics that had a slow start, but in recent years has really taken off. The slow start is likely to be attributed to the fact that it was perceived as hard to setup and maintain. But...

mysqli_result iterations

mysqli_result iterations
For the last few months I had quite a few MySQL blog posts and didn't have anything from my "new features in PHP [trunk|5.4]" series. This article is a bridge between those two. The PHP 5.4 NEWS file has a small entry: MySQLi: Added iterator support in MySQLi. mysqli_result implements Traversable. (Andrey, Johannes) From the outside it is a really small change and easy to miss. The mentioned class, mysqli_result, implements an interface which adds no new methods. What once can't see is that this...

PHPMaster.com: Localizing PHP Applications "The Right Way", Part 3

PHPMaster.com: Localizing PHP Applications "The Right Way", Part 3
PHPMaster.com has posted its third part of its "Localizing PHP Applications 'The Right Way'" series. In this third part you'll learn more about locales and message domain switching.In Part 2 you gained more insight into using the gettext library by learning the most important functions of the extension. In this part you'll learn how to best use a fallback locale, switch between locales, and override the currently selected message domain.They show you how to set up the directory structure to handle a...

PHP 5.4.0RC1 for OS X on php-osx.liip.ch

PHP 5.4.0RC1 for OS X on php-osx.liip.ch
Just a quick note. I uploaded the first build of the Release Candidate 1 of PHP 5.4.0 to php-osx.liip.ch. It works on Mac OS X 10.6 and 10.7. See the beta instructions for some info about how to install this. And keep on testing (and filing issues, if you find any)

Hackathon 2011!

Hackathon 2011!
Still wrapping up Horde Hackathon 2011, but it's been a ton of fun and very productive already.

Travis, CI for OSS

Travis, CI for OSS
Continuous integration is one of these topics that had a slow start, but in recent years has really taken off. The slow start is likely to be attributed to the fact that it was perceived as hard to setup and maintain. But solutions around Jenkins and Sismo are making it easier and easier. But thanks to the new Travis CI service, its now essentially so easy that there is no excuse not to use CI for PHP projects, at least if you are hosting your OSS code on github.com. What makes this service so crazy cool...

Getting started writing ZF2 modules

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. As an example,...

Getting started writing ZF2 modules

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. As an example,...

php|architect: Finding Exactly Where You Are

php|architect: Finding Exactly Where You Are
On the php|architect site today Chris Tankersley has a new tutorial about geocoding, Finding Exactly Where You Are - a guide to integrating the Yahoo! Placefinder service into your application.Yahoo! PlaceFinder is a REST web service that will turn an address into the latitudinal and longitudinal coordinates in XML, JSON, or serialized PHP objects. It has a few other functions too, like finding the nearest airport, time zone, and even telephone area code. [...] PlaceFinder is a very simple REST service,...

PHPBuilder.com: Building RESTful Web Services with the Zend Framework

PHPBuilder.com: Building RESTful Web Services with the Zend Framework
New on PHPBuilder.com today is a tutorial introducing you to web services with the Zend Framework, a guide to creating a simple RESTful service with this popular PHP framework.Rather than attempt to build and maintain multiple versions of the Web application in order to accommodate the diverse array of challenges and advantages presented by each device type, developers are increasingly embracing a unified approach which allows them to manage a single server-side code base which communicates with multiple...

Latest PHP Tweets