Re: [PHP] Re: calling php functions as library or cmd line

2005-01-15 Thread Jochem Maas
Cere Davis wrote: Geeze, That was obnoxious. you have to admit (well no you don't actually!) tho, it was damn tempting to just answer yes :-) anyway... Luckily google helped me out eventually: if (basename($argv[0]) == basename(__FILE__)) { ...so that bit of code allows you to differentiate betwe

[PHP] Re: calling php functions as library or cmd line

2005-01-14 Thread Cere Davis
Geeze, That was obnoxious. Luckily google helped me out eventually: if (basename($argv[0]) == basename(__FILE__)) { Robert Cummings wrote: > On Thu, 2005-01-13 at 09:46, Cere Davis wrote: >> Does anyone know how to write php libraries in a modular way so that you >> can both test the librari