Zend Server beta for PHP on IBM i: I like it

UPDATE: As of 2020, we recommend using Seiden PHP on IBM i and LINUX for reliability, speed, and ease of maintenance.


I’m recommending that people try Zend Server beta for IBM i if they’re using PHP on the IBM i. Even though it’s in beta, Zend Server brings improvements over its predecessors, Zend Core and Zend Platform. Improvements include:

  • Easy new user interface combining the best of Core and Platform
  • Better interface makes it easier for people to discover and use features such as code tracing and debugging
  • Elimination of mandatory proxy server (always a thorn in my side!)
  • Use of IBM’s supported, full-featured, flexible Apache server rather than the limited PASE server
  • Better performance

One caveat: the current beta version (as of February, 2010) is missing some functionality that will be available in the generally available (GA) release. Temporarily missing functionality includes:

  • no support for the mail() function (use Zend_Mail or Phpmailer instead in the meantime)
  • inclusion of an older version of the ibm_db2 driver. This version doesn’t have support for the “i5_libl” option. Ask Zend to send you the updated db2 driver if you need it.

I’m looking forward to trying the next beta version and eventually the GA release.

I believe Zend Server will shorten the learning curve for new users and simplify advanced configurations for us “veterans.”

Download it here: Zend Server beta for IBM i

PHP on IBM i (and me) at ZendCon 2009

This year’s ZendCon (Oct. 20-22, 2009, in San Jose, Calif.), the premier PHP conference, features several presentations about developing with PHP on the IBM i, including one by me!

Come hear me speak about “Zend Framework for Enterprise PHP on IBM i” on Tuesday, Oct. 20, 2009, at 4pm.

For details, go to http://www.zendcon.com.

Speaker: Zend/PHP Conference 2009

Our Zend Framework-based Site Honored by IBM/COMMON

UPDATE: As of 2020, we recommend using Seiden PHP on IBM i and LINUX for reliability, speed, and ease of maintenance.


We won! IBM has recognized my use of PHP and Zend Framework, and our entire team’s RPG/DB2 and design work, by naming our web solution the IBM i’s most innovative of 2009.

At IBM’s 2009 COMMON conference, IBM awarded the Power Systems Innovation Award for Best Web Solution for eBiz@ABG. The site, developed with my colleagues at  Strategic Business Systems, Inc., was created for New Jersey’s largest wine and spirits wholesaler, Allied Beverage Group.

The system offers product ordering, live inventory levels and pricing, and a full-text search of Allied’s large product catalog. The application was built with Zend Framework (the leading PHP framework) and runs entirely on Allied’s IBM i, leveraging Allied’s db2 database and time-tested RPG logic.

The site is password-protected, so unfortunately I can’t link to it here.

eBiz@ABG is one of the first sites to be built with Zend Framework on IBM i (System i, i5, iSeries, AS/400). It was a true collaboration with Allied, made easier because we all spoke the language of “i.” What’s more, by using large chunks of Allied’s existing RPG code that already handled the complex business logic, we saved time and avoided reinventing the wheel.

Zend Framework worked so well that I committed to mastering it and teaching the community about it. (ZF has a learning curve, but after that curve is mastered, ZF speeds development and offers easy maintenance and growth.) I earned my Zend Framework certification in August 2008, becoming one of the first 50 worldwide to do so and the first ZF-certified “i” professional. Since then, I’ve gone on to be a ZF/i mentor for other development teams, and have become a public speaker, sharing my PHP/ZF/i roadmap at conferences.

Thanks to Allied for the opportunity to collaborate on a great project; thanks to Strategic Business Systems for the support; and thanks to IBM for the award.

Why Use a PHP Framework?

At last night’s NY-PHP gathering, a fellow PHP’er and I discussed PHP frameworks. I told her I was developing an e-commerce site using Zend Framework. She replied that she’d been considering frameworks, especially Cake and Symfony, “but I’m not sure I need a framework at all. I write my own SQL; my apps work fine. What would a framework do for me?”

Setting aside the differences between PHP frameworks, I’m aware of at least 4 reasons to use them:

  1. Modular design: A home-grown application, with its ad hoc growth, can become a tangled mess that’s hard to change or enhance. Most mainstream frameworks provide a modular design that makes it easier to modify or add components.
  2. Flexible components: Sure, you can write your own authorization class in PHP, but why reinvent the wheel? The framework will provide an integrated component that handles not only your current needs, but requirements that you haven’t yet encountered (but that the framework’s community has). With a framework, chances are that you won’t have to redesign your authorization system when the users ask for something new.
  3. Best practices: As you use the framework, you’ll begin to absorb the practices and (we hope) good habits of the framework’s creators.
  4. New capabilities: Frameworks regularly add functionality to help developers implement new technology. These days, common enhancements involve AJAX and connections to the APIs of popular web service providers.

Developers may understandably wonder if mastering a framework is worth the learning curve. In my opinion, the effort to learn a framework will be repaid with applications that are well structured, flexible, and easily maintained.

My first open-source project: Mantis/400

Mantis/400 adds DB2 support to Mantis, the popular PHP-based bug tracking application. I programmed the upgrade with Ira Chandler of Curbstone Corporation, personnel from IBM and Zend, and Mantis’s Victor Boctor.

Mantis/400 runs on IBM System i (formerly AS/400), using Zend Core for i5.

Even before we got involved, Mantis supported several databases, thanks to the ADOdb Database Abstraction Library for PHP (and Python). ADOdb’s support of DB2 needed help, though, so we improved it, particularly for System i’s version of DB2.

I recommend the open-source process to anyone who enjoys learning a lot and meeting good people. Our team zestily shared knowledge and discoveries.

More information is available in Alex Woodie’s story in IT Jungle: Mantis Bug Tracker Ported to i5/OS.

Brand your site with a favicon

Favicons are those eye-catching little pictures that appear in your web browser’s address bar, favorites list (hence the name favicon, short for “favorites icon”), and, with modern tabbed browsers, on tabs.

Instantly recognizable when designed well, favicons represent the brand identity of sites that use them.

Examples

Wikipedia uses the “W” from its logo:
Wikipedia’s favicon

Digg’s favicon represents a person holding a shovel, an image that seems to have been created especially for the favicon:
Digg’s favicon

Usability in a tabbed, multitasking world

Tabbed browsers, such as Firefox and Internet Explorer 7, can show many page-tabs at once, squishing a site’s descriptive text.
Below are examples of tabs without favicons. What sites are they? I don’t know.
FireFox tabs without favicons

These have favicons. At a glance I see a seated robed figure (meditation site), a stylized “Ti” that I recognize as my private TikiWiki site, and a picture of me, which (if I can stop admiring its beauty for a moment), I know represents my blog.
FireFox tabs with favicons

Create your own mini work of art

Favicons are ordinary graphics, generally 16×16 pixels in size, named favicon.ico. How to make them? I found an easy method that even non-artists can use.

The free site Favicon Generator allows anyone to convert a normal-sized graphic into a favicon. Instructions:

  1. Go to Favicon Generator.
  2. Click the “Browse…” button to select an image from your computer’s hard drive.
  3. Click “Create Favicon.”
  4. When it’s ready, click the “Download the generated favicon” link to get the files.
  5. Download the zip file and extract favicon.ico to your computer. Then transfer that file, via FTP or your preferred method, to your website’s root folder (often /public_html or /www).
  6. View your website with its new addition! (You might have to press the refresh button to make the favicon appear.)

Show your art

If this article inspired you to create a favicon, please add a comment here with the link to your newly enhanced site.

Protect Your Eyes Against Computer Vision Syndrome (CVS)

Eye strain is a common complaint from computer users, but eyes aren’t the only part of the body that can hurt. Neck pain and backaches can also result from poor visual ergonomics.

In my latest article, Protect Your Eyes Against Computer Vision Syndrome (CVS) (requires free registration after about May 18, 2007), I show several ways to keep your eyes comfortable at the computer.

People who wear bifocals or trifocals should consider occupational progressive lenses, glasses that are made especially for daily computer use. These special glasses can resolve painful postural problems.

Money-saving tip: if you need to buy special (occupational) glasses for computer use, you may not need to buy new frames. Your optician will be happy to use old frames that you might have saved from old prescriptions.

New York Software Industry Association writes about my work with System i/PHP

My work to foster PHP on IBM System i was noted in the Feb. 21, 2007, edition of buzz@nysia, the New York Software Industry Association’s weekly news report. I am delighted that buzz@nysia columnist Donna Bogatin chose me as a featured “mover and shaker.”

Arrange Your Workstation to Protect Yourself Against Repetitive Strain Injury (RSI)

If you’re reading this blog, you need to protect yourself against Repetitive Strain Injury (RSI). As we work and explore the internet, we accumulate little stresses and habits that can hurt us over time.

MC Press just published my piece on how to arrange your computer workstation to avoid injury.

For my research, I interviewed Steve Shostack, former ergonomics consultant to NASA, and Paul Linden, Ph.D. Paul, an aikido teacher and Feldenkrais practitioner, wrote Comfort at Your Computer. I also recommend Paul’s free e-book, Reach Out: Body Awareness Training for Peacemaking, downloadable from www.being-in-movement.com.

Space did not permit me to write about my conversation with Mary Barbe, Ph.D., a researcher at Temple University. According to Dr. Barbe, recent human studies show that repetitive work causes the release of cytokines, proteins that trigger inflammation. The inflammation is not limited to the local area of overwork, but spreads throughout the body, potentially exacerbating conditions such as heart disease. The cytokines also help the body to rest by causing sensations of lethargy or even depression. Not good for productivity! In future articles, I will write about such hidden effects of RSI.

Meanwhile, read how to arrange your computer workstation to avoid injury. Stay healthy!

PHP mail() on IBM System i

My new article about mail() is available at MC Press Online. The article covers:

  • Zend Core’s implementation of mail() for IBM System i
  • How mail() compares to packages such as PHPMailer
  • Function definition and example
  • How to configure SMTP in Zend Core
  • Overriding defaults with ini_set
  • Troubleshooting

(This article is no longer available.)