a plea for sanity from PHP
Posted January 23rd, 2008 by Evan
from a cat named Evan.
Is there any way out there in the universe to add database support for, oh, say Oracle to PHP *without* having to recompile the farking thing?
- Evan's blog
- Login or register to post comments
Comments
I seem to recall that it's possible, even on Windows
Is PHP running on a Windows box? I gotta assume so since it's usually easy enough to recompile on Linux.
It's been a couple of years now, but I worked on a project that used PHP & Oracle, served via Apache on WinNT. It did require shoving a couple of DLLs into the proper directory, but not compiling to speak of. The instructions on this page seem familiar: www.oracle.com/technology/pub/notes/technote_php_instant.html. I also remember that it was always the OCI8 interface that we used, even though we were running Oracle9i. From the looks of it, that's still the story for 10g.
As with all things Oracle, some head-banging is inevitable.
Actually, it's on Solaris 10
Thanks for the tip but this is running on Solaris 10 with the Sun Java System Web Server 7.0 update 2.
The piece I am curious about is why PHP seems to require so many compile time options. In my opinion it is a major design failing in the structure of the language if you need to recompile each time you wish to add a new feature or switch databases!
I am starting to drift from the "roll your own" camp and much prefer the extend at run-time model that pretty much every other language I have used embraces.
Compiling PHP
The College's site is PHP on Solaris, but it uses a MySQL database. No help there.
I find PHP's compile approach reasonable. The run-time model just means compiling in absolutely everything from the get-go, and I prefer a lean install: fewer moving parts means less that can go wrong. I'd just as soon not have Postgres, Oracle, and DB2 support gunking up the executable if I'm just using MySQL.
That said, I know the pain of having to wade through huge install files just to enable one simple rinky-dink little feature. Given that Solaris is now somewhat of an "exotic" platform (especially for PHP), you also have to contend with the occasional head-scratching compiler error.
I guess not
http://forum.java.sun.com/thread.jspa?forumID=759&threadID=5145805