Subversion Repositories Applications.papyrus

Compare Revisions

Ignore whitespace Rev 1018 → Rev 1019

/trunk/papyrus/applications/installateur/instal_fichier.inc.php
32,7 → 32,7
// | (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF |
// | THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
// +------------------------------------------------------------------------------------------------------+
// CVS : $Id: instal_fichier.inc.php,v 1.10 2005-09-23 14:20:23 florian Exp $
// CVS : $Id: instal_fichier.inc.php,v 1.11 2006-10-06 14:46:15 alexandre_tb Exp $
/**
* Page de création des fichiers nécessaire à l'installation de Papyrus.
*
46,7 → 46,7
*@author Patrick PAUL
*@author Jean-Pascal MILCENT <jpm@tela-botanica.org>
*@copyright Tela-Botanica 2000-2004
*@version $Revision: 1.10 $ $Date: 2005-09-23 14:20:23 $
*@version $Revision: 1.11 $ $Date: 2006-10-06 14:46:15 $
// +------------------------------------------------------------------------------------------------------+
**/
 
158,6 → 158,21
$txt_ecriture_conf_erreur .= '<xmp>'.$configCode.'</xmp>'."\n";
$txt_ecriture_conf_erreur .= '</div>'."\n";
$erreur = testerConfig($sortie_verif, $txt_ecriture_conf, $fp, $txt_ecriture_conf_erreur, 1, $erreur);
// tentative d ecriture du fichier .htaccess
$url_ftp_htaccess = 'ftp://'.$fichier['PAP_FTP_UTILISATEUR'].':'.$fichier['PAP_FTP_MOT_DE_PASSE'].
'@'.$fichier['PAP_FTP_SERVEUR'].$fichier['PAP_FTP_RACINE'].'/.htaccess';
if (file_exists($pref['PAP_CHEMIN_RACINE'].'/.htaccess')) {
$sortie_verif .'<p>Attention: Un fichier .htaccess est déjà présent sur le serveur.'.
'<br />Veillez à le configurer correctement<br /><br />'.
'Contenu par défaut: <br /><br /> ErrorDocument 404 /erreur_404.php';
} else {
preg_match('/^(\/.*?)([^\/]+?)(?:\?(.*)|)$/', $_SERVER['REQUEST_URI'], $tab_prefixe);
$prefixe = $tab_prefixe[2];
$handle =fopen ($url_ftp_htaccess, 'w');
fwrite ($handle, 'ErrorDocument 404 /'.$prefixe.'erreur_404.php');
fcloas($handle);
}
}
}
 
245,6 → 260,9
/* +--Fin du code ----------------------------------------------------------------------------------------+
*
* $Log: not supported by cvs2svn $
* Revision 1.10 2005/09/23 14:20:23 florian
* nouvel habillage installateur, plus correction de quelques bugs
*
* Revision 1.9 2005/04/12 16:09:45 jpm
* Amélioration de la gestion de la constante de redirection des urls et de la gestion des constantes de type entier et booléen.
*