PHP problems

esaul esaul at reggaetrain.com
Thu Dec 4 19:17:18 PST 2003


On Fri, 05 Dec 2003 05:16:54 +0000, Jeremy Utley wrote:

> In article <1070577357.13041.7.camel at warpcore.tpegg.org>, Thomas Pegg wrote:
>> On Thu, 2003-12-04 at 12:37, esaul wrote:
>><snip>
>>> mysql_create_db($DBName); returns:
>> 
>>> Fatal error: Call to undefined function: mysql_create_db() in
>>> /var/www/htdocs/CreateDB.php on line 27
>>> 
>> This is due to since you built PHP and MySQL (I'm assuming version
>> 4.0.15a, which is whats in the BLFS book v.5 anyway) then that function
>> will not work, with that version of MySQL you would have to use a
>> version of MySQL in the 3.23.5x series.)
>> 
>> Read the warning block in the php documentation on this page:
>> http://www.php.net/manual/en/function.mysql-create-db.php
>><snip>
>> 
>> 
>> Thomas
> 
> Strange - I used that combination for quite a while with no problems
> (MySQL 4.x and PHP 4.x).  I suspect that the problem actually comes
> down to the MySQL library file not being in the ld search path.
> 
> Try adding /usr/lib/mysql to /etc/ld.so.conf.
> 
> -J-

Actually, Thomas was right. The funny thing is that I had that exact page
right in front of me on the other box, but I neglected to read the warning
thing thingy thing. Indeed, mysql_create_db() is atrophied.
See, MySQL knows where her (English language is gender weird) libraries
are at, and as long as mysql_pconnect() doesn't generate an error, we
could be certain that it is not the library search issue, ne c'est pas?
Now, correct me if I am wrong, but how could you possibly use this
function in MySQL 4.0.15+ when it's deprecated? Granted, one could write a
function doing this, and albeit very simple, it would be useful (in terms
of making the code better readable).
Now, on to the next stage, the idea is to phase out dispatchers in a bike
courier company, so that the registered clients could simply enter the 
address to pick up a package, and where to deliver it to. The bike
couriers have e-mail enabled pagers. Most regular clients have less 
than five steady destinations, so they could simply click on the map for
the pick up spot, and the destination spot; a calculator will give them
the price tag, and an elite courier will cheat on their employer to make
the delivery. The web-site has to figure out which messenger is the
closest (according to the previous calls), and forward the request.

There are tons of couriers all over the place. Every large city depends
on dozens if not hundreds of couriers. They are employed as
subcontractors, which means that they don't get sick days, health
insurance, and they have to repair their bikes themselves, buy winter
clothing to ride, all at their expense. Damn, this is starting to sound
like a k5 moushy article.
But, seriously, bicycle couriers worldwide, unite! (if the kids were
united . . . blah, blah).
Avoiding the bureaucracy of dispatchers, replacing them with a simple
website could put a few bucks in the workers' pockets. The code is/will be
GPLed so that anyone can use it.

peace



More information about the blfs-support mailing list