newtech Posted November 24, 2006 Share Posted November 24, 2006 When you go to step 14 of the install directions, then words are french, anyone have the english version of step 14? STEP 14: Add to /catalog/admin/includes/functions/general.php //Cache function rdel($path, $deldir = true) { // $path est le chemin relatif au fichier php // $deldir (paramètre optionel, par défaut à vrai) permet de dire si vous souhaitez supprimer le répertoire (vrai) ou le vider uniquement (faux) // on vérifie d'abord que le nom du repertoire contient "/" à la fin, sinon on le lui rajoute if ($path[strlen($path)-1] != "/") $path .= "/"; if (is_dir($path)) { $d = opendir($path); while ($f = readdir($d)) { if ($f != "." && $f != "..") { $rf = $path . $f; // chemin relatif au fichier php if (is_dir($rf)) // si c'est un répertoire on appel récursivement la fonction rdel($rf); else // sinon on efface le fichier unlink($rf); } } closedir($d); if ($deldir) // si $deldir est vrai on efface le répertoire rmdir($path); } else { unlink($path); } } Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.