RE: [PHP-DB] photos in a folder

From: Date: Sun, 23 Nov 2003 03:44:53 +0000
Subject: RE: [PHP-DB] photos in a folder
References: 1  Groups: php.db 
Request: Send a blank email to php-db+get-31703@lists.php.net to get a copy of this message
I'd personally use a SQL DB Class(PHPLib has a good one - http://phplib.netuse.de ) Also for this you need the File Class which you can get at http://www.thewebmasters.net Basicly then just use the FileClass to Produce a Dir Listing then do a 'for' statement for every file, then query that file name via the SQL Class if there is no matchs then delete the file _________________ Nigel Jones njonez@ihug.co.nz >> -----Original Message----- >> From: elias [mailto:e-male@majoros.com] >> Sent: Sunday, November 23, 2003 3:14 PM >> To: php-db@lists.php.net >> Subject: [PHP-DB] photos in a folder >> >> >> Hey. first of, im really new to PHP, so im still learning. >> >> The problem i have now is: >> >> i have a dir with 600+ photos, and a database with 500+ photos >> (due to the >> fact that when i deleted photos from my webpage, i apparently >> only deleted >> it from the database, and not the dir. >> >> so.. can someone please tell me how to do a batch script that >> compares the >> dir with the database, and deletes the file thats not in the database? >> >> thanks >> /elias >> >> -- >> PHP Database Mailing List (http://www.php.net/) >> To unsubscribe, visit: http://www.php.net/unsub.php >> >>

« previous php.db (#31703) next »