[CLUE-Tech] Why PHP rules!

Jeremiah Stanley miah at miah.org
Thu Feb 8 14:22:56 MST 2001


Good to hear that you like PHP! It has all the things I like about Perl
and gets rid of the things I don't by being specialized for web
developement.

> Now, there is one thing left, that MS has actually done well.  ODBC, 
> although limited is a good idea.  Give one way to talk to databases that 
> covers the basics, and write drivers to do this with any database.  There 
> is a UNIX ODBC, but I have not seen much support for this.  PERL does this 
> well, with DBI, but a general purpose one would be best.  Does anyone know 
> of anything?   It would be nice to do development with one database, and 
> then switch if needed.

I've never been much of an ODBC fan but there are some wrappers that allow
for this to happen under PHP. One of them is: 

http://php.weblogs.com/ADODB

You are correct that Perl does do this with the DBI interface, but I have
never seen this switch databases well. I recently worked on switching from
mSQL to MySQL (mSQL is the spawn of something very evil...) using the
DBI. While our scripts didn't change all that much, our database schema
was crippled by having to stay with the mSQL formats (MySQL is much more
powerful, the only thing I like better is PostgreSQL for features).

The reality of it is that if you switch databases you should probably
think about just modularizing your code so that you have one part that
handles all of your database connections/retrieving you data and another
part that does nothing but work on displaying your data. Smart design over
depending on features.

Here are some more links to websites that I've found useful for PHP
learning:

http://www.php.net		/* Duh! */
http://www.devshed.com		This one has good but short articles about
				topics over all of web dev.
http://www.phpbuilder.com	Great site, I've stolen alot of code from
				them in the past.
http://www.phpwizard.net	This one is put together by Tobias himself
				and has some really good tutorials on
				using XML with PHP. Their links page is a
				great resource as well.

Hope this helps you out some.

Jeremiah Stanley
-- 
Q: How do you keep a moron in suspense?





More information about the clue-tech mailing list