php developer

› DevShed: An Introduction to the Observer Pattern in PHP

DevShed is starting off a new series today with the first part of their look at design patterns, specifically this time, the Observer pattern.

If you have reached the point in your programming life where you are using design patterns, you will want to read this article. The first of a three-part series, it covers the Observer pattern, which can be just the thing for situations where objects need to send information to a centralized mechanism.

I hope you'll be wondering how all this boring theory can be translated into functional PHP code. That's what I'm going to do in the course of this article, by introducing some friendly examples of how to implement the Observer pattern in PHP applications.

They just right in and create a more practical example, opting for demonstration over a lot of explaination. Their sample code manipulates strings to change them to uppercase and save them off to a file. They attach a basic error logger to it and then conform it to fit in with the Observer pattern style.

17/07/2006 8:48 pm (UTC)   PHP Developer   View entry   Digg!  digg it!   del.icio.us  del.icio.us

php developer

› Andi Gutmans' Blog: PHP 5 Adoption has Tipped!

According to this new post on Andi Gutmans' blog today, the adoption of PHP versions seems to be tipping in favor of PHP5.

PHP 5 was released in July 2004. Since its release two years ago, there has been a lot of talk about its adoption rate and whether it will surpass the PHP 4 installed base. No doubt that it will still take some time for PHP 5 to reach PHP 4's existing installed base. The main reason for this are the numerous PHP 4-based applications that were built over the years, and if it's not broken, don't fix it.

He includes a graph showing the adoption of both PHP4 and PHP5 versions, noting a large increase from the release of the 5.1 version of PHP.

Although I knew many were waiting for PHP 5.1 before upgrading, its release in last November seems to have created a huge increase in PHP 5 adoption. In July over 74% of support tickets were by customers using PHP 5 (and remember we do support both versions).
17/07/2006 12:45 pm (UTC)   PHP Developer   View entry   Digg!  digg it!   del.icio.us  del.icio.us

tobias schlitt  eZ systems employee

› PHPUGDO plans "PHP introduction workshop"

During our last usergroup meeting here in Dortmund (last Thursday), the idea came up to organize a "PHP introduction day", if there is enough interesst in the local area. The idea resulted from the success of Kores and my "PHP best practices talk" at FrOSCon?. We generally thought about making a whole day event, where we will teach people PHP basics in the morning and some advanced stuff (like best practices, usage of components, etc.) in the afternoon. So I emailed the students mailinglist of our computer science faculty at university and our Linux AG mailinglist from university, if there is interesst. By now we have over 50 interessted people, which is really amazingly cool! The plans evolved further again and we think about making a 2 day event, where we provide PHP basisc on day 1 in the morning, then give people the chance to code a small application in the afternoon, where we give assistance (so a real "workshop"). On day 2 we will then teach the advanced section and let people also code a small app, using some advanced techniques, like OO patterns and component libraries.

This is all still in a very early planning stage, but maybe there are people in the Ruhrgebiet area, which I did not reach by email so far, who have interesst in such an event. If you do have interesst, please comment on this blog entry or email me, so we can estimate the number of attendees. The event will be free of charge and probably be held at the University of Dortmund.

16/07/2006 1:21 pm (UTC)   Tobias Schlitt   View entry   Digg!  digg it!   del.icio.us  del.icio.us

php developer

› Icant.co.uk: How to create thumbnails with PHP and gd

One of the best moves that the PHP language developers could have made was to bring the GD library code "into the fold" and integrate it with recent PHP installations. This makes it easy to manipulate images and customize things on the fly. Another thing it allows is the generation of thumbnails for your site, either dynamically or in something like a cron job. Want to know how? Well, read up here.

In this article from Icant.co.uk, they step you through the creation of these smaller, lighter versions of your images with lots of code and explainations. Topics covered include:

  • The logic of batch processing thumbnails
  • The PHP functions to use
  • The main thumbnail generation function

They also include instructions on how to check your installation for GD support and how to load it if it's not already there (module support).

14/07/2006 1:26 pm (UTC)   PHP Developer   View entry   Digg!  digg it!   del.icio.us  del.icio.us

php developer

› Greg Beaver's Blog: phpDocumentor and __get/__set/__call - give us your ideas (RFC)

In his latest post today, Greg Beaver is also taking a look at phpDocumentor and some of the documentation methods it allows, noting that providing the right notes on the "magic" functions has always been a point of difficulty.

One of the trickier feature requests for phpDocumentor has been documenting "magic" object properties and methods. By "magic" I am referring to properties and methods that are created dynamically by PHP 5.0+ userspace class methods __get, __set, __isset, __unset and __call.

He gives a code example of creating properties and a magic function (borp). To illustrate his point, he tries to specify the phpDocumentor format that would go with it - not an exact match, but with the help o ffour new tags it's made easier: @property, @property-read, @property-write, and @method.

14/07/2006 1:06 pm (UTC)   PHP Developer   View entry   Digg!  digg it!   del.icio.us  del.icio.us

php developer

› Mike Kornienko's Blog: Integration of Spry and PHP/MySQL

On Macdiggs.com, the blog of Mike Kornienko, there's a new post with his look at integrating Adobe's Spry Ajax framework into a simple PHP/MySQL application.

Adobe have recently released its Spry Ajax framework for public beta-test by developers and I've been playing with this baby for a while. And here's some kind of report of what I have learned.

Spry is Adobe's Ajax library for manipulating XML data. It has some very unique and pretty useful functions like regions handling, related auto-updating data and stuff like that.

In his example he creates a simple backend script (PHP) that pulls out the data from MySQL and converts it to XML. With that to pull from, he creates, using Spry, functionality to read in the XML and display it in an HTML table. He also demonstrates how to sort the results automatically based on a certain column (the ID column, which he defines as a number using the setColumnType).

13/07/2006 1:29 pm (UTC)   PHP Developer   View entry   Digg!  digg it!   del.icio.us  del.icio.us

php developer

› Utah PHP Users Group: PHP-CAPTCHA

On the Utah PHP Users Group website today, there's a quick new tutorial concerning the creation of a CAPTCHA image for your site (using the GD functionality in PHP).

The following article includes code and examples on how to prevent bots from taking part in online polls, registering for free email accounts, more recently, preventing bot-generated spam by requiring that the (unrecognized) sender pass a CAPTCHA test before the email message is delivered [implemented in Yahoo]. They have also been used to prevent people from using bots to assist with massive downloading of content from multimedia websites.

First, they create the form the entire example centers around before even looking at the code. With that laid down and explained, they get into the image creation and addition of the string to make the "humans only" image. Finally, they show how to check the word entered for the CAPTCHA verification against a session variable to see if they're a match.

13/07/2006 12:34 pm (UTC)   PHP Developer   View entry   Digg!  digg it!   del.icio.us  del.icio.us

bård farstad  eZ systems employee

› A certified eZ publish developer

eZ systems have now just launched the eZ publish Developer Certification.

I tested the exam and I passed! This means that I can use this banner on my blog:


Oh, I am not going to tell you how many answers I made wrong. But I can say that I did pass it with more than 70% which is what you need to pass the exam.

13/07/2006 10:16 am (UTC)   Bård Farstad   View entry   Digg!  digg it!   del.icio.us  del.icio.us

php developer

› Chronosight Blog: Inline AJAX Calendar using PHP

On the Chronosight Blog, there's a follow-up post with a look at some enhancements to the original tutorial - Simple Calendar Tutorial.

Almost a year ago I made a tutorial on Simple Calendar Tutorial which trained us to develop a calendar using PHP. Now it times to enhance that tutorial to a whole new level. Let trou in some AJAX code and Javascript Document Object Model (DOM) to create not one, but three type of calendar: Single Calendar, Time Period Selection Calendar, Month-Year Calendar

He steps you through the creation of two files - one to provide a space for the Ajax interface and another for the calendar PHP class. Toss in a little CSS and some explainations along the way and you have all that you need to make a simple, easy to use calendaring system.

12/07/2006 9:46 pm (UTC)   PHP Developer   View entry   Digg!  digg it!   del.icio.us  del.icio.us

paul borgermans

› Second release of our Lucene based search plugin for eZ publish

.. or an open source ECMS meets an open source enterprise level search engine . If you are using eZ publish and are in control of the servers it runs on, please test our contribution (beta) by downloading: http://ez.no/community/contribs/applications/lucene_java_search_plugin Though you need to install the php-java bridge as an additional php extension, it is worth the trouble [...]
12/07/2006 4:21 pm (UTC)   Paul Borgermans   View entry   Digg!  digg it!   del.icio.us  del.icio.us

eZ publish™ copyright © 1999-2005 eZ systems as