PHP for nothing

With a tip of the hat to Nick who is quite a lot better at this than I am, and an apology to Dire Straits

Now look at them yo-yo's that's the way you do it
You write your software with the PDT
That ain't workin' that's the way you do it
PHP for nothin' and scripts for free

Driving in this morning, I thought it’d be easy to do the whole song. It turns out that it was hard enough to just do the first verse.

The Eclipse PHP Development Tools (PDT) version 1.0 was officially released today with much fanfare. I’ve been using the project for a while, and have been quite happy with the milestone releases. I’ve only just started using the 1.0 release version, but I’m expecting rich PHP development goodness.

Getting the PDT is relatively easy. Hook your Eclipse update manager to the update site and you’re off to the races. I did, however, hit a snag on my first attempt to update the PDT feature. Here’s the error I received:

Unable to complete action for feature "PDT Feature" due to errors.
  The File
is not a valid JAR file. [error in opening zip file]
  error in opening zip file
  The File
is not a valid JAR file. [error in opening zip file]
  error in opening zip file

After some careful inspection, it turns out that the names of the PDT plug-in files, coupled with some unfortunate default web server/PHP configuration, is the culprit. What’s happening is that some of the mirror web servers see a request to download files like org.eclipse.php.core_1.0.0.v20070917.jar and interpret it as a request that needs to be handled by php (it’s the “.php” in the name). The Eclipse Webmasters have fixed our configurations to deal with this and so have some of the mirrors; but not all mirrors have made the fix yet. So you may see this error (or one just like it) when you tray to install.

We’re working on a long term solution (see Bug 203794), but in the meantime, your best bet for successfully installing or updating PDT is to force the update manager to use a mirror that doesn’t suffer from this problem (like You can tell Eclipse to stop automatic mirror selection by turning off the checkbox on the “Install/Update” page in the the preferences

This entry was posted in Uncategorized. Bookmark the permalink.

One Response to PHP for nothing

  1. Tonsil says:

    Thanks for posting this – I hit the same snag just now. I appreciate that a quick search turned up this post, and allowed me to get past it quickly. Thanks!

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s