Re: The PHP Platform
| From: | Stig S. Bakken | Date: | Fri, 12 Apr 2002 23:35:02 +0000 |
| Subject: | Re: The PHP Platform | ||
| References: | 1 | Groups: | php.dev |
| Request: | Send a blank email to php-dev+get-82715@lists.php.net to get a copy of this message | ||
On Fri, 2002-04-12 at 22:31, Ken Egervari wrote:
> Hello everyone,
>
> I think as we go forward with PHP and as PHP 5 is nearing, shouldn't we planning on
> developing a PHP Platform? Basically the Java or .NET Platform - a set of stable and well written
> class libraries in which everyone can use? Classes that make sense for every day and maybe not-so
> every day PHP development? With .NET and Java out there, PHP is really falling short. It's
> not even efficient to develop in any more other than that its tools are free. I tried to start such
> an initiative with eXtremePHP, but only 2 developers go so far. We need a community to help build a
> large platform that provides classes for everything a PHP developer might need.
>
> Why am I saying this? Well, looking at DOM XML, PHP still hasn't gotten it right. Even
> though there are several great implementations out there in other languages, PHP is slowly building
> towards those already bugged-out, well written designs. I was recently doing a project and now that
> PHP 4.1.2 has changed the DOM XML library without making any changes to the documentation, this move
> seriously messed up my work as well as many others. In my case, I have to use the latest version so
> I had to migrate a lot of code. I know that the library was considered experimental, but the design
> decisions were made poorly while they could have just emulated the w3c bindings which were already
> thought out and used across the world as far as Java and many other languages are concerned. I
> think the PHP developers and community should start moving towards a mature platform with an even
> larger goal in mind rather than just a set of functions. With the RAD tools provided by .NET and
> Jav!
a, PHP is giving less and less of a reason for capable developers to use the language because it
really only solves the needs of HTML developers that need some dynamic functionality to their sites.
I guess the future is in the hands of its leaders to make the right calls. It will be a test to
see which calls are made.
I agree that PHP needs a platform like you mention. Today, PHP has a
zillion extensions each providing nice functionality, but there is very
little interoperability between extensions. For example, none of the
XML-related extensions (domxml, xslt, xml) are able to interoperate. If
PHP had a good platform, you could take part of your DOM tree and use
the xslt extension to render it. Not to mention the all-different
database extensions.
Wez took a great first step by implemting PHP streams. This is the kind
of integration we need. There are lots of other things we can do add
"sudden reusability" in many parts of PHP, such as a common C API to
database extensions, an abstracted type system that can map data more
easily between SQL databases, HTML forms, Web Services etc., flexible
exception handling and so on.
PEAR does not offer this today, but it offers the infrastructure
necessary to build and deploy such a platform (PEAR is a lot more than a
bunch of classes).
My intent is to bundle core PEAR packages into the PFC (PHP Foundation
Classes). PFC is just the platform you are calling for. Until now I
have focused my energy on building the PEAR infrastructure, so people
such as yourself can go ahead and make the platform. If you already
have written a lot of code, we should definitely work together.
Today the PEAR installer is self-maintainable, it's able to update
itself from the web, which is good enough for me to be comfortable
releasing it. PHP 4.2.0 will contain a self-maintainable PEAR
installer, and 4.3.0 will go one step further and bundle package
tarballs instead of plan .php files.
- Stig