|
From: <os...@us...> - 2011-10-31 11:49:14
|
Revision: 3852
http://oscss.svn.sourceforge.net/oscss/?rev=3852&view=rev
Author: oscim
Date: 2011-10-31 11:49:06 +0000 (Mon, 31 Oct 2011)
Log Message:
-----------
Deport du dossier Documents dans le dossier catalog, et deport lors install si utilisation vhost
Modification creation des fichiers lors de l'install bas?\195?\169 sur des modeles
Ajustement de l'instalation, prise en compte vhost/classique
Modified Paths:
--------------
trunk/catalog/install/includes/classes/core.php
trunk/catalog/install/includes/content/core.base.php
trunk/catalog/install/includes/content/core.configuration.php
trunk/catalog/install/includes/content/core.modes.php
trunk/catalog/install/includes/sql/mysql/data/91_osc_configuration_group.sql
Added Paths:
-----------
trunk/catalog/Documents/
trunk/catalog/install/includes/modele/
trunk/catalog/install/includes/modele/admin_configure.txt
trunk/catalog/install/includes/modele/admin_htaccess.txt
trunk/catalog/install/includes/modele/configure.txt
trunk/catalog/install/includes/modele/htaccess.txt
trunk/catalog/install/includes/modele/robot.txt
trunk/catalog/install/includes/modele/tables_files_modules.txt
Removed Paths:
-------------
trunk/Documents/
Modified: trunk/catalog/install/includes/classes/core.php
===================================================================
--- trunk/catalog/install/includes/classes/core.php 2011-10-31 08:02:09 UTC (rev 3851)
+++ trunk/catalog/install/includes/classes/core.php 2011-10-31 11:49:06 UTC (rev 3852)
@@ -73,7 +73,7 @@
}
/**
- Delete repertoire recursif
+ @brief Delete repertoire recursif
*/
function recurse_delete($src){
$dir = opendir($src);
@@ -93,11 +93,11 @@
}
/**
- Copy repertoire recursif
+ @brief Copy repertoire recursif
*/
function recurse_copy($src,$dst){
$dir = opendir($src);
- @mkdir($dst);
+ if(!is_dir($dst))@mkdir($dst);
while(false !== ( $file = readdir($dir)) ) {
if (( $file != '.' ) && ( $file != '..' )) {
if ( is_dir($src . '/' . $file) ) {
@@ -112,7 +112,7 @@
}
/**
- retour lang item
+ @brief retour lang item
*/
public function l10n($str) {
global $lang;
@@ -245,7 +245,7 @@
$res=array();
$count=0;
while($file = readdir($fichier)){
- if(!in_array($file, array(".","..")) && !is_dir($file)){
+ if(!in_array($file, array(".","..")) && (substr($file,-1) !='~') && (substr($file,-4) !='.svn') && !is_dir($file)){
$count++;
$name=substr($file, 0,-4);
$res[(isset($orderby[$name])?$orderby[$name] : $count)]=
Modified: trunk/catalog/install/includes/content/core.base.php
===================================================================
--- trunk/catalog/install/includes/content/core.base.php 2011-10-31 08:02:09 UTC (rev 3851)
+++ trunk/catalog/install/includes/content/core.base.php 2011-10-31 11:49:06 UTC (rev 3852)
@@ -23,38 +23,49 @@
// 'conf_f_admin'=>'admin/includes/filenames.php',
'root_doc'=>'Documents/',
-// 'root_doc'=>'Documents/',
-// 'root_doc_oscss_data'=>'Documents/oscss_data/',
- 'root_doc_sessions'=>'Documents/sessions/',
-// 'root_doc_sessions'=>'Documents/admin/sessions/',
+ 'root_doc_a_a'=>'Documents/admin/',
+ 'root_doc_a_backups'=>'Documents/admin/backups/',
+ 'root_doc_a_cache'=>'Documents/admin/cache/',
+ 'root_doc_a_contrib'=>'Documents/admin/contributions/',
+ 'root_doc_a_data'=>'Documents/admin/data/',
+ 'root_doc_a_logs'=>'Documents/admin/logs/',
+ 'root_doc_a_sessions'=>'Documents/admin/sessions/',
+ 'root_doc_a_tmp'=>'Documents/admin/tmp/',
+ 'root_doc_p_p'=>'Documents/public/',
+ 'root_doc_p_log'=>'Documents/public/logs/',
+ 'root_doc_p_data'=>'Documents/public/oscss_data/',
+ 'root_doc_p_sessions'=>'Documents/public/sessions/',
+
+
+
'htacces_admin'=>'admin/.htaccess',
- 'admin_back'=>'admin/backups/',
- 'admin_cip'=>'admin/contributions/',
+ 'admin'=>'admin/',
+ 'admin_inc'=>'admin/includes/',
'admin_image'=>'admin/images/',
'admin_graph'=>'admin/images/graphs/',
'admin_image'=>'admin/images/imagecache/',
- 'admin_mod_a'=>'admin/includes/modules/account/',
- 'admin_mod_c'=>'admin/includes/modules/categories/',
- 'admin_mod_g'=>'admin/includes/modules/generic/',
- 'admin_mod_p'=>'admin/includes/modules/products/',
- 'admin_tmp'=>'admin/includes/tmp/',
- 'admin_tmp_cache'=>'admin/includes/tmp/cache/',
- 'admin_sessions'=>'admin/sessions/',
- 'common'=>'common/',
- 'common_classes'=>'common/classes/',
+// 'admin_mod_a'=>'admin/includes/modules/account/',
+// 'admin_mod_c'=>'admin/includes/modules/categories/',
+// 'admin_mod_g'=>'admin/includes/modules/generic/',
+// 'admin_mod_p'=>'admin/includes/modules/products/',
+// 'admin_tmp'=>'admin/includes/tmp/',
+// 'admin_tmp_cache'=>'admin/includes/tmp/cache/',
+// 'admin_sessions'=>'admin/sessions/',
+// 'common'=>'common/',
+// 'common_classes'=>'common/classes/',
'download'=>'download/',
- 'images'=>'images/',
+// 'images'=>'images/',
'images'=>'images/imagecache/',
- 'mod_a'=>'includes/modules/account/',
- 'mod_g'=>'includes/modules/generic/',
- 'mod_l'=>'includes/modules/listing/',
- 'mod_o'=>'includes/modules/order_total/',
- 'mod_py'=>'includes/modules/payment/',
- 'mod_p'=>'includes/modules/products/',
- 'mod_s'=>'includes/modules/shipping/',
- 'oscss_data'=>'oscss_data/',
+// 'mod_a'=>'includes/modules/account/',
+// 'mod_g'=>'includes/modules/generic/',
+// 'mod_l'=>'includes/modules/listing/',
+// 'mod_o'=>'includes/modules/order_total/',
+// 'mod_py'=>'includes/modules/payment/',
+// 'mod_p'=>'includes/modules/products/',
+// 'mod_s'=>'includes/modules/shipping/',
+// 'oscss_data'=>'oscss_data/',
'pub'=>'pub/',
// 'sessions'=>'sessions/',
'templates'=>'templates/'
@@ -106,6 +117,7 @@
while ($r=each($this->ctr)){
$type= (preg_match("#/$#i",$r['value'])) ?'rep' : 'file';
if(!isset($_POST['WS_STORE_ADMIN']) && !empty($_POST['WS_STORE_ADMIN']))$r['value']=str_replace('admin', $_POST['WS_STORE_ADMIN'],$r['value']);
+
if ($type=='file'){
if (file_exists($path.$r['value'])) {
if (!is_writable($path.$r['value'])){
@@ -115,20 +127,22 @@
}else {
$rep=preg_replace("#[a-z]*\.[a-z]*#i",'',$r['value']);
if (!is_writable($path.$rep)){
- $this->PileMessage('alert',core::l10n("Le répertoire n'est pas accessible en écriture : ").$rep);
+ $this->PileMessage('alert',core::l10n("Le répertoire n'est pas accessible en écriture : ").$path.$rep);
$this->err=true;
}
}
- } else {
- chdir($path);
+ }
+ else {
+ if(!empty($path))chdir($path);
+
if(!is_dir($r['value']) && !@mkdir($r['value'],0777)){
$this->PileMessage('alert',core::l10n("Le répertoire n'existe pas et ne peut être créé : "). $r['value']);
$this->err=true;
}elseif (!is_writable($r['value'])){
- $this->PileMessage('alert',core::l10n("Le répertoire n'existe pas et ne peut être créé : "). $r['value']);
+ $this->PileMessage('alert',core::l10n("Le répertoire existe mais les droits ne sont pas suffisants: "). $r['value']);
$this->err=true;
}
- chdir('install/');
+ if(!empty($path))chdir('install/');
}
unset($type);
}
Modified: trunk/catalog/install/includes/content/core.configuration.php
===================================================================
--- trunk/catalog/install/includes/content/core.configuration.php 2011-10-31 08:02:09 UTC (rev 3851)
+++ trunk/catalog/install/includes/content/core.configuration.php 2011-10-31 11:49:06 UTC (rev 3852)
@@ -2,21 +2,82 @@
/**
@licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
@package oscss-2 <www http://www.oscss.org>
- @version 2.1.0
- @date 12/12/10, 09:15
+ @version 2.1.1
+ @date 31/10/11, 11:30
@author oscim <mail aur...@os...> <www http://www.oscim.fr>
Ayatus <www http://www.ayatus.org>
@encode UTF-8
+
+ @brief This class use modele in includes/modele/xxx.txt
+ In the modele , use %XXXX_XXX% For replace in reel file
+
+ For call and install new file, use in this class
+
+ $res=file_get_contents(self::$modele_path.'configure.txt');
+
+ $file_contents = '<?php' ."\n";
+ $file_contents .=str_replace(self::$c_k, self::$c_v ,$res);
+ $file_contents .= "\n".'?>';
+
+
+ Tableau des Correspodnance
+ [CURRENT_VERSION] => 2.1.1
+ [CREATE_DATE] => 2011-10-31 12:00:44
+ [VAR_OSCSS_DEBUG] => true
+ [HTTP_SERVER] => http://localhost
+ [HTTPS_SERVER] =>
+ [ENABLE_SSL] => false
+ [HTTP_COOKIE_DOMAIN] =>
+ [HTTPS_COOKIE_DOMAIN] =>
+ [HTTP_COOKIE_PATH] => /workspace/oscss_test/2.1.1/08/trunk/catalog/
+ [HTTPS_COOKIE_PATH] =>
+ [HTTP_CATALOG] => /workspace/oscss_test/2.1.1/08/trunk/catalog/
+ [FS_DOCUMENT_ROOT] => /var/www/workspace/oscss_test/2.1.1/08/trunk/catalog/
+ [WS_DOCUMENT_ROOT] => /workspace/oscss_test/2.1.1/08/trunk/catalog/
+ [FS_ROOT_DOCS] => /var/www/workspace/oscss_test/2.1.1/08/trunk/Documents/
+ [WS_ADMIN] => /workspace/oscss_test/2.1.1/08/trunk/catalog/admin613
+ [FS_ADMIN] => /var/www/workspace/oscss_test/2.1.1/08/trunk/catalog/admin613
+ [HTTP_WORK_DIRECTORY] => Documents/
+ [DB_SERVER] => localhost
+ [DB_SERVER_USERNAME] => root
+ [DB_SERVER_PASSWORD] => aurelien
+ [DB_DATABASE] => oscss_211_08_innodb
+ [DB_TABLE_PREFIX] => osc_
+ [USE_PCONNECT] => false
+ [STORE_SESSIONS] =>
+ [DBMOTOR] => Mysql
+ [DBMOTOR_CHARSET] => utf8
+ [DBMOTOR_PORT] => 3306
+ [DBMOTOR_TYPE] => InnoDB
+ [SECURE_KEY] => 1d2bf0664163e0b7562f90c9f3de2518b26cac28
+
+
*/
class configuration extends core {
+ /**
+ @var
+ */
+ static protected $c_k = array() ;
+ /**
+ @var
+ */
+ static protected $c_v = array() ;
+ /**
+ @var
+ */
+ static protected $corresp = array() ;
+ /**
+ @var
+ */
+ static protected $modele_path = 'includes/modele/';
/**
- Installation des fichier de configurations
+ @brief create all linnk and var for global configuration
*/
- private function install_base_conf(){
+ private function AdjustConf(){
$http_url = parse_url($_POST['HTTP_WWW_ADDRESS']);
$http_server = $http_url['scheme'] . '://' . $http_url['host'];
@@ -44,257 +105,124 @@
$http_work_directory = $_POST['HTTP_WORK_DIRECTORY'];
if (substr($http_work_directory, -1) != '/') $http_work_directory .= '/';
+
+ $root_docs = $this->fs_document_root . $http_work_directory;
+ if (isset($_POST['ARBORESANCE']) )
+ if($_POST['ARBORESANCE'] =='vhost')
+ $root_docs = substr($this->fs_document_root,0, -(int)strlen('catalog/') ) . $http_work_directory;
+
$Key=sha1(mt_rand(10000,99999).time());
- $file_contents = '<?php' . "\n" .
- '/**'. "\n" .
- ' @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce '. "\n" .
- ' @package oscss-2 <www http://www.oscss.org>'. "\n" .
- ' @version 2.1.0'. "\n" .
- ' @date '.date("Y-m-d").''. "\n" .
- ' @author oscim <mail aur...@os...> <www http://www.oscim.fr>'. "\n" .
- ' @encode UTF-8'. "\n" .
- '*/'. "\n" .
- '' . "\n" .
+ $this->get_db_conf();
- ' /**' . "\n" .
- ' * \brief as active / inactive cache and error return' . "\n" .
- ' * @var boolean default:false' . "\n" .
- ' */' . "\n" .
- ' define(\'OSCSS_DEBUG\', true);' . "\n" .
- ' /**' . "\n" .
- ' * \brief as active view query in error requet sql' . "\n" .
- ' * @var boolean default:false' . "\n" .
- ' */' . "\n" .
- ' define(\'OSCSS_SHOW_QUERIES\', true);' . "\n" .
- ' /**' . "\n" .
- ' * \brief as active / incative garbage collector error' . "\n" .
- ' * @var boolean default: true' . "\n" .
- ' */' . "\n" .
- ' define(\'OSCSS_GARBAGE_ERROR\', true);' . "\n" .
- '' . "\n" .
- '// Define the webserver and path parameters' . "\n" .
- '// * DIR_FS_* = Filesystem directories (local/physical)' . "\n" .
- '// * DIR_WS_* = Webserver directories (virtual/URL)' . "\n" .
- ' define(\'HTTP_SERVER\', \'' . $http_server . '\'); // eg, http://localhost - should not be empty for productive servers' . "\n" .
- ' define(\'HTTPS_SERVER\', \'' . $https_server . '\'); // eg, https://localhost - should not be empty for productive servers' . "\n" .
- ' define(\'ENABLE_SSL\', ' . $enable_ssl . '); // secure webserver for checkout procedure?' . "\n" .
- ' define(\'HTTP_COOKIE_DOMAIN\', \'' . (($http_cookie_domain !='localhost')? $http_cookie_domain: '') . '\');' . "\n" .
- ' define(\'HTTPS_COOKIE_DOMAIN\', \'' . (($https_cookie_domain !='localhost')? $https_cookie_domain: '') . '\');' . "\n" .
- ' define(\'HTTP_COOKIE_PATH\', \'' . $http_cookie_path . '\');' . "\n" .
- ' define(\'HTTPS_COOKIE_PATH\', \'' . $https_cookie_path . '\');' . "\n" .
- ' define(\'DIR_WS_HTTP_CATALOG\', \'' . $http_catalog . '\');' . "\n" .
- ' define(\'DIR_WS_HTTPS_CATALOG\', \'' . $https_catalog . '\');' . "\n" .
- ' define(\'DIR_CLASSES\', \'classes/\');' . "\n" .
- ' define(\'DIR_FUNCTIONS\', \'functions/\');' . "\n" .
- ' define(\'DIR_FONTS\', \'fonts/\');' . "\n" .
- '' . "\n" .
- ' define(\'DIR_WS_IMAGES\', \'images/\');' . "\n" .
- ' define(\'DIR_WS_ICONS\', DIR_WS_IMAGES . \'icons/\');' . "\n" .
- ' define(\'DIR_WS_INCLUDES\', \'includes/\');' . "\n" .
- ' define(\'DIR_WS_BOXES\', DIR_WS_INCLUDES . \'boxes/\');' . "\n" .
- ' define(\'DIR_WS_FUNCTIONS\', DIR_WS_INCLUDES . DIR_FUNCTIONS);' . "\n" .
- ' define(\'DIR_WS_CLASSES\', DIR_WS_INCLUDES . DIR_CLASSES);' . "\n" .
- ' define(\'DIR_WS_MODULES\', DIR_WS_INCLUDES . \'modules/\');' . "\n" .
- ' define(\'DIR_WS_LANGUAGES\', DIR_WS_INCLUDES . \'languages/\');' . "\n" .
- ' define(\'DIR_WS_TRIGGERS\', DIR_WS_INCLUDES . \'triggers/\');' . "\n" .
- ' define(\'DIR_WS_DOWNLOAD_PUBLIC\', \'pub/\');' . "\n" .
- '' . "\n" .
- ' define(\'DIR_FS_CATALOG\', \'' . $this->fs_document_root . '\');' . "\n" .
- ' define(\'DIR_FS_ROOT_DOCS\', \'' . $this->fs_document_root . 'Documents/\');' . "\n" .
- ' define(\'DIR_FS_CATALOG_IMAGES\', DIR_FS_CATALOG . \'images/\');' . "\n" .
- ' define(\'DIR_FS_CATALOG_MODULES\', DIR_FS_CATALOG . \'includes/modules/\');' . "\n" .
- ' define(\'DIR_FS_CATALOG_LANGUAGES\', DIR_FS_CATALOG . \'includes/languages/\');' . "\n" .
- ' define(\'DIR_FS_CATALOG_TEMPLATE\', DIR_FS_CATALOG . \'templates/\');' . "\n" .
- ' define(\'DIR_FS_WORK\', \'' . $http_work_directory . '\');' . "\n" .
- ' define(\'DIR_FS_DOWNLOAD\', DIR_FS_CATALOG . \'download/\');' . "\n" .
- ' define(\'DIR_FS_DOWNLOAD_PUBLIC\', DIR_FS_CATALOG . \'pub/\');' . "\n" .
- '' . "\n" .
- ' define(\'DIR_FS_SESSIONS\', DIR_FS_ROOT_DOCS . \'public/sessions/\');' . "\n" .
- '' . "\n" .
- '// Template System files' . "\n" .
- ' define(\'DIR_FS_TEMPLATES\', DIR_FS_CATALOG . \'templates/\');' . "\n" .
- ' define(\'DIR_WS_TEMPLATES\', \'templates/\');' . "\n" .
- '' . "\n" .
- '// Common' . "\n" .
- ' define(\'DIR_WS_COMMON\', \'common/\');' . "\n" .
- ' define(\'DIR_WS_COMMON_FUNCTIONS\', DIR_WS_COMMON . DIR_FUNCTIONS);' . "\n" .
- ' define(\'DIR_WS_COMMON_FONTS\', DIR_WS_COMMON . DIR_FONTS);' . "\n" .
- ' define(\'DIR_WS_COMMON_CLASSES\', DIR_WS_COMMON . DIR_CLASSES);' . "\n" .
- ' define(\'DIR_WS_COMMON_IMAGES\', DIR_WS_TEMPLATES . \'layout/\');' . "\n" .
- '' . "\n" .
- '// define our database connection' . "\n" .
- ' define(\'DB_CONNECTOR\', \'mysql\');' . "\n" .
- ' define(\'DB_PORT\', \'3306\');' . "\n" .
- ' define(\'DB_CHARSET\', \'utf8\');' . "\n" .
- ' define(\'DB_SERVER\', \'' . $_POST['DB_SERVER'] . '\'); // eg, localhost - should not be empty for productive servers' . "\n" .
- ' define(\'DB_SERVER_USERNAME\', \'' . $_POST['DB_SERVER_USERNAME'] . '\');' . "\n" .
- ' define(\'DB_SERVER_PASSWORD\', \'' . $_POST['DB_SERVER_PASSWORD']. '\');' . "\n" .
- ' define(\'DB_DATABASE\', \'' . $_POST['DB_DATABASE']. '\');' . "\n" .
- ' define(\'DB_TABLE_PREFIX\', \'' . $_POST['DB_TABLE_PREFIX']. '\');' . "\n" .
- ' define(\'USE_PCONNECT\', \'' . ((isset($_POST['USE_PCONNECT']) && $_POST['USE_PCONNECT'] == 'on') ? 'true' : 'false') . '\'); // use persistent connections?' . "\n" .
- ' define(\'STORE_SESSIONS\', \'' . ((isset($_POST['STORE_SESSIONS']) && $_POST['STORE_SESSIONS'] == 'files') ? '' : 'mysql') . '\'); // leave empty \'\' for default handler or set to \'mysql\'' . "\n" .
- '' . "\n" .
- ' /**' . "\n" .
- ' @var Security key' . "\n" .
- ' @brief use by offline mode' . "\n" .
- ' */' . "\n" .
- ' $SecuKey=\''.$Key.'\';' . "\n" .
- '?>';
+ /**
+ Creation admin configure
+ */
+ $corresp = array();
+ $corresp['CURRENT_VERSION'] = '2.1.1';
+ $corresp['CREATE_DATE'] = date("Y-m-d H:i:s");
+ $corresp['VAR_OSCSS_DEBUG'] = 'true';
+ $corresp['HTTP_SERVER'] = $http_server;
+ $corresp['HTTPS_SERVER'] = $https_server;
+ $corresp['ENABLE_SSL'] = $enable_ssl;
+ $corresp['HTTP_COOKIE_DOMAIN'] = (($http_cookie_domain !='localhost')? $http_cookie_domain: '');
+ $corresp['HTTPS_COOKIE_DOMAIN'] = (($https_cookie_domain !='localhost')? $https_cookie_domain: '');
+ $corresp['HTTP_COOKIE_PATH'] = $http_cookie_path;
+ $corresp['HTTPS_COOKIE_PATH'] = $https_cookie_path;
+ $corresp['HTTP_CATALOG'] = $http_catalog;
+ $corresp['FS_DOCUMENT_ROOT'] = $this->fs_document_root;
+ $corresp['WS_DOCUMENT_ROOT'] = $this->ws_document_root;
+ $corresp['FS_ROOT_DOCS'] = $root_docs;
+ $corresp['WS_ADMIN'] = $http_catalog .$this->ws_admin_rand.'/';
+ $corresp['FS_ADMIN'] = $this->fs_document_root.$this->ws_admin_rand.'/' ;
+ $corresp['HTTP_WORK_DIRECTORY'] = $http_work_directory;
+ $corresp['DB_SERVER'] = $this->db['DB_SERVER'];
+ $corresp['DB_SERVER_USERNAME'] = $this->db['DB_SERVER_USERNAME'];
+ $corresp['DB_SERVER_PASSWORD'] = $this->db['DB_SERVER_PASSWORD'];
+ $corresp['DB_DATABASE'] = $this->db['DB_DATABASE'];
+ $corresp['DB_TABLE_PREFIX'] = $this->db['DB_TABLE_PREFIX'];
+ $corresp['USE_PCONNECT'] = ((isset($_POST['USE_PCONNECT']) && $_POST['USE_PCONNECT'] == 'on') ? 'true' : 'false');
+ $corresp['STORE_SESSIONS'] = ((isset($_POST['STORE_SESSIONS']) && $_POST['STORE_SESSIONS'] == 'files') ? '' : 'mysql');
+ $corresp['DBMOTOR'] = $this->db['DBMOTOR'];
+ $corresp['DBMOTOR_CHARSET'] = $this->db['DBMOTOR_CHARSET'];
+ $corresp['DBMOTOR_PORT'] = $this->db['DBMOTOR_PORT'];
+ $corresp['DBMOTOR_TYPE'] = $this->db['DBMOTOR_TYPE'];
+ $corresp['SECURE_KEY'] = $Key;
+// print_r($corresp);
+// exit;
+ self::$corresp = $corresp;
+ function remove(&$item2){
+ $item2 = "%".$item2."%";
+ }
+ self::$c_k=array_keys($corresp);
+ array_walk(self::$c_k, 'remove');
+
+ self::$c_v=array_values($corresp);
+
+ }
+
+
+ /**
+ Installation des fichier de configurations
+ */
+ private function install_base_conf(){
+
+
+
+
+ /**
+ @remarks adjust hierarchie folder by radio select
+ */
+ if (isset($_POST['ARBORESANCE']) ){
+
+ if($_POST['ARBORESANCE'] =='all'){
+
+ /**
+ @remarks Add htacess for secure folder and childs
+ */
+
+ }
+ elseif($_POST['ARBORESANCE'] =='vhost'){
+ /**
+ @remarks Copy to up folder
+ */
+ if(file_exists(self::$corresp['FS_DOCUMENT_ROOT']. 'Documents/')) {
+ parent::recurse_copy(self::$corresp['FS_DOCUMENT_ROOT']. 'Documents/', self::$corresp['FS_ROOT_DOCS']);
+
+ parent::recurse_delete(self::$corresp['FS_DOCUMENT_ROOT']. 'Documents/');
+ }
+ }
+ }
+
+
+
+
+ $res=file_get_contents(self::$modele_path.'configure.txt');
+
+ $file_contents = '<?php' ."\n";
+ $file_contents .=str_replace(self::$c_k, self::$c_v ,$res);
+ $file_contents .= "\n".'?>';
+
$fp = fopen($this->fs_document_root . 'includes/configure.php', 'w');
fputs($fp, $file_contents);
fclose($fp);
- $file_contents =
- '<?php' . "\n" .
- '/**'. "\n" .
- ' @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce '. "\n" .
- ' @package oscss-2 <www http://www.oscss.org>'. "\n" .
- ' @version 2.1.0'. "\n" .
- ' @date '.date("Y-m-d").''. "\n" .
- ' @author oscim <mail aur...@os...> <www http://www.oscim.fr>'. "\n" .
- ' @encode UTF-8'. "\n" .
- '*/'. "\n" .
- '' . "\n" .
- ' /**' . "\n" .
- ' * \brief as active / inactive cache and error return' . "\n" .
- ' * @var boolean default:false' . "\n" .
- ' */' . "\n" .
- ' define(\'OSCSS_DEBUG\', true);' . "\n" .
- ' /**' . "\n" .
- ' * \brief as active view query in error requet sql' . "\n" .
- ' * @var boolean default:false' . "\n" .
- ' */' . "\n" .
- ' define(\'OSCSS_SHOW_QUERIES\', true);' . "\n" .
- ' /**' . "\n" .
- ' * \brief as active / incative garbage collector error' . "\n" .
- ' * @var boolean default:true' . "\n" .
- ' */' . "\n" .
- ' define(\'OSCSS_GARBAGE_ERROR\', true);' . "\n" .
- '' . "\n" .
- '// Define the webserver and path parameters' . "\n" .
- '// * DIR_FS_* = Filesystem directories (local/physical)' . "\n" .
- '// * DIR_WS_* = Webserver directories (virtual/URL)' . "\n" .
- ' define(\'HTTP_SERVER\', \'' . $http_server . '\'); // eg, http://localhost - should not be empty for productive servers' . "\n" .
- ' define(\'HTTPS_SERVER\', \'' . $https_server . '\'); // eg, https://localhost - should not be empty for productive servers' . "\n" .
- ' define(\'HTTP_CATALOG_SERVER\', \'' . $http_server . '\');' . "\n" .
- ' define(\'HTTPS_CATALOG_SERVER\', \'' . $https_server . '\');' . "\n" .
- ' define(\'ENABLE_SSL\', ' . $enable_ssl . ');' . "\n" .
- ' define(\'ENABLE_SSL_CATALOG\', \'' . $enable_ssl . '\'); // secure webserver for catalog module' . "\n" .
- ' define(\'DIR_FS_DOCUMENT_ROOT\', \'' . $this->fs_document_root . '\'); // where the pages are located on the server' . "\n" .
- ' define(\'DIR_WS_ADMIN\', \'' . $http_catalog .$this->ws_admin_rand. '/\'); // absolute path required' . "\n" .
- ' define(\'DIR_FS_ADMIN\', \'' . $this->fs_document_root.$this->ws_admin_rand . '/\'); // absolute pate required' . "\n" .
- ' define(\'DIR_WS_CATALOG\', \'' . $http_catalog . '\'); // absolute path required' . "\n" .
- ' define(\'DIR_WS_HTTP_CATALOG\',DIR_WS_CATALOG);// compatibilité SEO' . "\n" .
- ' define(\'DIR_WS_HTTPS_CATALOG\', \'' . $https_catalog . '\');' . "\n" .
- ' define(\'DIR_FS_CATALOG\', \'' . $this->fs_document_root . '\'); // absolute path required' . "\n" .
- ' define(\'DIR_FS_ROOT_DOCS\', \'' . $this->fs_document_root . 'Documents/\');' . "\n" .
- ' define(\'DIR_CLASSES\', \'classes/\');' . "\n" .
- ' define(\'DIR_FUNCTIONS\', \'functions/\');' . "\n" .
- ' define(\'DIR_FONTS\', \'fonts/\');' . "\n" .
- ' define(\'DIR_LOGS\', \'logs/\');' . "\n" .
- ' define(\'DIR_CACHE\', \'cache/\');' . "\n" .
- '' . "\n" .
- ' define(\'DIR_WS_IMAGES\', \'images/\');' . "\n" .
- ' define(\'DIR_WS_ICONS\', DIR_WS_IMAGES . \'icons/\');' . "\n" .
- ' define(\'DIR_WS_CATALOG_IMAGES\', DIR_WS_CATALOG . \'images/\');' . "\n" .
- ' define(\'DIR_WS_INCLUDES\', \'includes/\');' . "\n" .
- ' define(\'DIR_WS_BOXES\', DIR_WS_INCLUDES . \'boxes/\');' . "\n" .
- ' define(\'DIR_WS_DOWNLOAD\', \'download/\');' . "\n" .
- ' define(\'DIR_WS_FUNCTIONS\', DIR_WS_INCLUDES . DIR_FUNCTIONS);' . "\n" .
- ' define(\'DIR_WS_CLASSES\', DIR_WS_INCLUDES . DIR_CLASSES);' . "\n" .
- ' define(\'DIR_WS_MODULES\', DIR_WS_INCLUDES . \'modules/\');' . "\n" .
- ' define(\'DIR_WS_LIB\', DIR_WS_INCLUDES . \'lib/\');' . "\n" .
- ' define(\'DIR_WS_PLUGINS\', DIR_WS_INCLUDES . \'plugins/\');' . "\n" .
- ' define(\'DIR_WS_FONTS\', DIR_WS_INCLUDES . DIR_FONTS);' . "\n" .
- ' define(\'DIR_WS_JS\', DIR_WS_INCLUDES . \'javascript/\');' . "\n" .
- ' define(\'DIR_WS_WIDGET\', DIR_WS_INCLUDES . \'widget/\');' . "\n" .
- ' define(\'DIR_WS_LANGUAGES\', DIR_WS_INCLUDES . \'languages/\');' . "\n" .
- ' define(\'DIR_WS_CATALOG_LANGUAGES\', DIR_WS_CATALOG . \'includes/languages/\');' . "\n" .
- '' . "\n" .
- ' define(\'DIR_FS_CATALOG_LANGUAGES\', DIR_FS_CATALOG . \'includes/languages/\');' . "\n" .
- ' define(\'DIR_FS_CATALOG_IMAGES\', DIR_FS_CATALOG . \'images/\');' . "\n" .
- ' define(\'DIR_FS_CATALOG_MODULES\', DIR_FS_CATALOG . \'includes/modules/\');' . "\n" .
- '' . "\n" .
- ' define(\'DIR_FS_BACKUP\', DIR_FS_ROOT_DOCS . \'admin/backups/\');' . "\n" .
- ' define(\'DIR_FS_WORK\', DIR_FS_ROOT_DOCS . \'admin/public/oscss_data/\');' . "\n" .
- ' define(\'DIR_FS_SESSIONS\', DIR_FS_ROOT_DOCS . \'admin/sessions/\');' . "\n" .
- ' define(\'DIR_FS_CIP\', DIR_FS_ROOT_DOCS . \'admin/contributions/\');' . "\n" .
- '' . "\n" .
- '// Template System files' . "\n" .
- ' define(\'DIR_FS_TEMPLATES\', DIR_FS_CATALOG . \'templates/\');' . "\n" .
- ' define(\'DIR_WS_TEMPLATES\', DIR_WS_CATALOG . \'templates/\');' . "\n" .
- ' define(\'DIR_WS_CATALOG_DOWNLOAD\', DIR_WS_CATALOG . \'download/\');' . "\n" .
- '' . "\n" .
- '// Common' . "\n" .
- ' define(\'DIR_WS_COMMON\', \'common/\');' . "\n" .
- ' define(\'DIR_WS_COMMON_FUNCTIONS\', DIR_WS_COMMON . DIR_FUNCTIONS);' . "\n" .
- ' define(\'DIR_WS_COMMON_FONTS\', DIR_WS_COMMON . DIR_FONTS);' . "\n" .
- ' define(\'DIR_WS_COMMON_CLASSES\', DIR_WS_COMMON . DIR_CLASSES);' . "\n" .
- ' define(\'DIR_WS_COMMON_IMAGES\', DIR_WS_TEMPLATES . \'layout/\');' . "\n" .
- '' . "\n" .
- '// define our database connection' . "\n" .
- ' define(\'DB_CONNECTOR\', \'mysql\');' . "\n" .
- ' define(\'DB_PORT\', \'3306\');' . "\n" .
- ' define(\'DB_CHARSET\', \'utf8\');' . "\n" .
- ' define(\'DB_SERVER\', \'' . $_POST['DB_SERVER'] . '\'); // eg, localhost - should not be empty for productive servers' . "\n" .
- ' define(\'DB_SERVER_USERNAME\', \'' . $_POST['DB_SERVER_USERNAME'] . '\');' . "\n" .
- ' define(\'DB_SERVER_PASSWORD\', \'' . $_POST['DB_SERVER_PASSWORD']. '\');' . "\n" .
- ' define(\'DB_DATABASE\', \'' . $_POST['DB_DATABASE']. '\');' . "\n" .
- ' define(\'DB_TABLE_PREFIX\', \'' . $_POST['DB_TABLE_PREFIX']. '\');' . "\n" .
- ' define(\'USE_PCONNECT\', \'' . ((isset($_POST['USE_PCONNECT']) && $_POST['USE_PCONNECT'] == 'true') ? 'true' : 'false') . '\'); // use persisstent connections?' . "\n" .
- ' define(\'STORE_SESSIONS\', \'mysql\'); // leave empty \'\' for default handler or set to \'mysql\'' . "\n" .
+ $res=file_get_contents(self::$modele_path.'admin_configure.txt');
+ $file_contents = '<?php' ."\n";
+ $file_contents .=str_replace(self::$c_k, self::$c_v ,$res);
+ $file_contents .= "\n".'?>';
- ''."\n".
- ' /**' . "\n" .
- ' * @brief method login active, separate by ;. the method is call in sort ' . "\n" .
- ' * @example $conf[\'login\']=\'oscss;openid\';' . "\n" .
- ' * @var $conf->login string ' . "\n" .
- ' */' . "\n" .
- ' $conf[\'login\']=\'oscss;\';' . "\n" .
- '' . "\n" .
- ' /**' . "\n" .
- ' @var Security key' . "\n" .
- ' @brief use by offline mode' . "\n" .
- ' */' . "\n" .
- ' $SecuKey=\''.$Key.'\';' . "\n" .
- '?>';
-
-
$fp = fopen($this->fs_document_root .$this->ws_admin_rand.'/includes/configure.php', 'w');
fputs($fp, $file_contents);
fclose($fp);
- $file_contents =
- '' . "\n" .
- '# @licence GPL 2005-'.date('Y').' The osCSS developers - osCSS Open Source E-commerce '. "\n" .
- '# @package oscss-2 <www http://www.oscss.org>'. "\n" .
- '# @version 2.1.0'. "\n" .
- '# @date '.date("Y-m-d").''. "\n" .
- '# @author oscim <mail aur...@os...> <www http://www.oscim.fr>'. "\n" .
- '# @encode UTF-8'. "\n" .
- '# Default OsCss exclusions' . "\n" .
- 'User-agent: *' . "\n" .
- 'Allow: /' . "\n" .
- ' Disallow: /admin*/' . "\n" .
- ' Disallow: /common/' . "\n" .
- ' Disallow: /download/' . "\n" .
- ' Disallow: /ext/' . "\n" .
- ' Disallow: /images/' . "\n" .
- ' Disallow: /includes/' . "\n" .
- ' Disallow: /install/' . "\n" .
- ' Disallow: /oscss_data/' . "\n" .
- ' Disallow: /sessions/' . "\n" .
- ' Disallow: /templates/' . "\n" .
- ' Disallow: /pub/' . "\n" .
- '' . "\n" .
- '# For sitemaps.xml autodiscovery.' . "\n" .
- ' Sitemap:http://www.monsite.com/sitemapindex.xml' . "\n" .
- '' . "\n";
+ $res=file_get_contents(self::$modele_path.'robot.txt');
+ $file_contents =str_replace(self::$c_k, self::$c_v ,$res);
+
$fp = fopen($this->fs_document_root . 'robots.txt', 'w');
fputs($fp, $file_contents);
fclose($fp);
@@ -311,191 +239,21 @@
if(file_exists($this->fs_document_root.'admin'))rename($this->fs_document_root.'admin',$this->fs_document_root.$this->ws_admin_rand);
}
elseif((isset($_POST['install']['rewrite']) && $_POST['install']['rewrite'] =='on' ) ) {
- /* Ecriture du htaccess admin */
- $file_contents =
- '# $Id: .htaccess,v 2.0 '.date("y.m.d").' oscim Exp $' . "\n" .
- '# <Directory "/usr/local/apache/htdocs">' . "\n" .
- '# AllowOverride Options' . "\n" .
- '# </Directory>' . "\n" .
- '# The following makes adjustments to the SSL protocol for Internet' . "\n" .
- '# Explorer browsers' . "\n" .
- '# <IfModule mod_setenvif.c>' . "\n" .
- '# <IfDefine SSL>' . "\n" .
- '# SetEnvIf User-Agent ".*MSIE.*" \ ' . "\n" .
- '# nokeepalive ssl-unclean-shutdown \ ' . "\n" .
- '# downgrade-1.0 force-response-1.0' . "\n" .
- '# </IfDefine>' . "\n" .
- '# </IfModule>' . "\n" .
- '# Fix certain PHP values' . "\n" .
- ' AddDefaultCharset UTF-8' . "\n" .
- '# FIX' . "\n" .
- '<IfModule mod_php5.c>' . "\n" .
- ' php_flag register_long_arrays Off' . "\n" .
- ' php_value register_globals off' . "\n" .
- '</IfModule>' . "\n" .
- '<IfModule mod_rewrite.c>' . "\n" .
- ' RewriteEngine on' . "\n" .
- ' RewriteBase '.$this->ws_document_root.$this->ws_admin_rand.'/' . "\n" .
- '' . "\n" .
- '# comment this line , if you not execute cron' . "\n" .
- ' RewriteRule (.*cronfile\.ph.*)$ $1 [L]' . "\n" .
- '' . "\n" .
- ' RewriteCond %{QUERY_STRING} (\<|%3C).*script.*(\>|%3E) [NC,OR]' . "\n" .
- ' RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]' . "\n" .
- ' RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})' . "\n" .
- ' RewriteRule ^(.*)$ index.php [F,L]' . "\n" .
- ' RewriteRule ^$ index.php?page_admin=index [L]' . "\n" .
- ' RewriteRule ^rss.php rss.php?%{QUERY_STRING} [L]' . "\n" .
- '' . "\n" .
- ' RewriteRule ^attributeManager/attributeManager/(.*)$ attributeManager/$1 [L]' . "\n" .
- ' RewriteRule ^(attributeManager/.*)$ $1 [L]' . "\n" .
- ' RewriteRule (.*plugins/.*)$ $1 [L]' . "\n" .
- ' RewriteRule (.*editeur/.*)$ $1 [L]' . "\n" .
- ' RewriteRule (.*template/.*)$ $1 [L]' . "\n" .
- ' RewriteRule (.*images/.*)$ $1 [L]' . "\n" .
- ' RewriteRule (.*includes/.*)$ $1 [L]' . "\n" .
- ' RewriteRule (.*\.css)$ $1[L]' . "\n" .
+ $res=file_get_contents(self::$modele_path.'admin_htaccess.txt');
+ $file_contents =str_replace(self::$c_k, self::$c_v ,$res);
- ' RewriteRule (.*logoff\.ph.*)$ $1 [L]' . "\n" .
- ' RewriteRule (.*login\.ph.*)$ $1 [L]' . "\n" .
- ' RewriteRule (.*document\.ph.*)$ $1 [L]' . "\n" .
- ' RewriteRule (.*password_forgotten\.ph.*)$ $1 [L]' . "\n" .
- ' RewriteRule (.*popup_image\.ph.*)$ $1 [L]' . "\n" .
- ' RewriteRule (.*login\.ph.*)$ $1 [L]' . "\n" .
- ' RewriteRule ([0-9A-Za-z_&=-]*)(.php)?(.*)$ index.php?page_admin=$1&%{QUERY_STRING} [L]' . "\n" .
-
- ' ErrorDocument 401 /' . "\n" .
- ' ErrorDocument 402 /' . "\n" .
- ' ErrorDocument 403 /' . "\n" .
- ' ErrorDocument 404 /' . "\n" .
- ' ErrorDocument 500 /' . "\n" .
- '</IfModule>' . "\n";
-
$fp = fopen($this->fs_document_root .$this->ws_admin_rand.'/.htaccess', 'w');
fputs($fp, $file_contents);
fclose($fp);
- /* Ecriture du htaccess */
- $file_contents =
- '# $Id: .htaccess,v 2.0 '.date("y.m.d").' oscim Exp $' . "\n" .
- '# <Directory "/usr/local/apache/htdocs">' . "\n" .
- '# AllowOverride Options' . "\n" .
- '# </Directory>' . "\n" .
- '# The following makes adjustments to the SSL protocol for Internet' . "\n" .
- '# Explorer browsers' . "\n" .
- '# <IfModule mod_setenvif.c>' . "\n" .
- '# <IfDefine SSL>' . "\n" .
- '# SetEnvIf User-Agent ".*MSIE.*" \ ' . "\n" .
- '# nokeepalive ssl-unclean-shutdown \ ' . "\n" .
- '# downgrade-1.0 force-response-1.0' . "\n" .
- '# </IfDefine>' . "\n" .
- '# </IfModule>' . "\n" .
- '# Fix certain PHP values' . "\n" .
- '## element pur hebergement mutulaiser, a commenter si inutile' . "\n" .
- 'SetEnv REGISTER_GLOBALS 0' . "\n" .
- 'SetEnv MAGIC_QUOTES 1' . "\n" .
- 'SetEnv PHP_VER 5' . "\n" .
- '' . "\n" .
- '# force default charset' . "\n" .
- ' AddDefaultCharset UTF-8' . "\n" .
- '# FIX' . "\n" .
- '<IfModule mod_php5.c>' . "\n" .
- ' php_flag register_long_arrays Off' . "\n" .
- ' php_value register_globals off' . "\n" .
- '</IfModule>' . "\n" .
- '' . "\n" .
- '<IfModule mod_rewrite.c>' . "\n" .
- '' . "\n" .
- '# 404 error ' . "\n" .
- ' ErrorDocument 404 /404.php' . "\n" .
- '' . "\n" .
- ' RewriteEngine on' . "\n" .
- ' RewriteBase '.$this->ws_document_root.'' . "\n" .
- '' . "\n" .
- ' RewriteCond %{QUERY_STRING} (\<|%3C).*script.*(\>|%3E) [NC,OR]' . "\n" .
- ' RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]' . "\n" .
- ' RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})' . "\n" .
- ' RewriteRule ^(.*)$ index.php [F,L]' . "\n" .
- '' . "\n" .
- '# rule for 404 page ' . "\n" .
- ' RewriteRule ^404.php$ index.php?_ID=404.php&%{QUERY_STRING}' . "\n" .
- '' . "\n" .
- '##newsletter trace opened email ' . "\n" .
- ' RewriteRule n-([0-9]+)-([0-9]+).jpg newsletters.php?mode=opened&newsID=$1&cID=$2 [L,QSA]' . "\n" .
- '' . "\n" .
- '# DEB Sans rewrite, placer des fichier du même nom a la racine' . "\n" .
- '# DEB Retrocompatibiliter' . "\n" .
- ' RewriteRule ^conditions.php$ index.php?content=3&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^contact.php$ index.php?_ID=contact.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^cookie_usage.php$ index.php?_ID=cookie_usage.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^info_shopping_cart.php$ index.php?_ID=info_shopping_cart.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^tell_a_friend.php$ index.php?_ID=tell_a_friend.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^featured_products.php$ index.php?_ID=featured_products.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^template.php$ index.php?_ID=template.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^privacy.php$ index.php?_ID=privacy.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^listing_best_sellers.php$ index.php?_ID=listing_best_sellers.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^listing_products_new.php$ index.php?_ID=listing_products_new.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^listing_small_price.php$ index.php?_ID=listing_small_price.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^listing_specials.php$ index.php?_ID=listing_specials.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^search_help.php$ index.php?_ID=search_help.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^ssl_check.php$ index.php?_ID=ssl_check.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^shopping_cart.php(.{0,})$ index.php?_ID=shopping_cart.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^shipping.php(.{0,})$ index.php?_ID=shipping.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^sitemap.php$ index.php?_ID=sitemap.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^remove_cart.php$ index.php?_ID=remove_cart.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^product_reviews.php$ index.php?_ID=listing_reviews.php&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^product_info.php$ index.php?products_id=$2&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^home.php?(.*)$ index.php?content=$1&%{QUERY_STRING}' . "\n" .
+ $res=file_get_contents(self::$modele_path.'htaccess.txt');
+ $file_contents =str_replace(self::$c_k, self::$c_v ,$res);
- ' RewriteRule ^account_([a-z_]*).php$ account.php?action=$1&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^address_([a-z_]*).php$ account.php?aca_mod=address_book&aca_type=account&aca_action=display_view&%{QUERY_STRING}' . "\n" .
- '' . "\n" .
- '# FIN Sans rewrite, placer des fichier du même nom a la racine' . "\n" .
- '# Prise en charge des appels vers les vidéo' . "\n" .
- '# RewriteRule ^playlist:([0-9]*)::type:([a-z]*)::pID:([0-9]*)::ext:.flv$ counter.php?action_type=$2&action_class=portfolio&method=counter_media&ppID=$1&products_id=$3 [L]' . "\n" .
- '# RewriteRule ^playlist:([0-9]*)::type:([a-z]*)::pID:([0-9]*)::ext:.mp3 counter.php?action_type=$2&action_class=portfolio&method=counter_media&ppID=$1&products_id=$3 [L]' . "\n" .
- '' . "\n" .
- '' . "\n" .
- '# MODE SEO Rewrite'. "\n" .
- ' RewriteRule ^(.*)-p-(.*).html$ index.php?products_id=$2&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^(.*)-c-(.*).html$ index.php?cPath=$2&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^(.*)-b-(.*).html$ index.php?content=$2&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^(.*)-m-(.*).html$ index.php?manufacturers_id=$2&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^(.*)-pi-(.*).html$ popup_image.php?pID=$2&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^(.*)-t-(.*).html$ index.php?content=$2&%{QUERY_STRING}' . "\n" .
- '# RewriteRule ^(.*)-pr-(.*).html$ product_reviews.php?products_id=$2&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^(.*)-pr-(.*).html$ index.php?_ID=listing_reviews.php&products_id=$2&%{QUERY_STRING}' . "\n" .
- '# RewriteRule ^(.*)-pri-(.*).html$ product_reviews_info.php?products_id=$2&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^(.*)-i-(.*).html$ information.php?info_id=$2&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^(.*)-d-(.*).html$ $2.php?divers=$2&%{QUERY_STRING}' . "\n" .
- ' RewriteRule ^(.*)-l-(.*).html$ $2.php?lID=$2&%{QUERY_STRING} [L]' . "\n" .
- ' RewriteRule ^(.*)-u-(.*).html$ index.php?customers_id=$2&%{QUERY_STRING} [L]' . "\n" .
- '' . "\n" .
- '# MODE SEO Rewrite-mode2 '. "\n" .
- ' RewriteRule ^p/([0-9]*)/(.*).html$ index.php?products_id=$1&%{QUERY_STRING} [L]' . "\n" .
- ' RewriteRule ^c/(.*)/(.*).html$ index.php?cPath=$1&%{QUERY_STRING} [L]' . "\n" .
- ' RewriteRule ^b/(.*)/(.*).html$ index.php?content=$1&%{QUERY_STRING} [L]' . "\n" .
- ' RewriteRule ^m/(.*)/(.*).html$ index.php?manufacturers_id=$1&%{QUERY_STRING} [L]' . "\n" .
- ' RewriteRule ^pi/(.*)/(.*).html$ popup_image.php?pID=$1&%{QUERY_STRING} [L]' . "\n" .
- ' RewriteRule ^t/(.*)/(.*).html$ index.php?content=$1%{QUERY_STRING} [L]' . "\n" .
- ' RewriteRule ^pr/(.*)/(.*).html$ index.php?_ID=listing_reviews.php&products_id=$1&%{QUERY_STRING} [L]' . "\n" .
- ' RewriteRule ^i/(.*)/(.*).html$ information.php?info_id=$1&%{QUERY_STRING} [L]' . "\n" .
- ' RewriteRule ^d/(.*)/(.*).html$ $1.php?divers=$1.php&%{QUERY_STRING} [L]' . "\n" .
- ' RewriteRule ^l/(.*)/(.*).html$ $1.php?lID=$1&%{QUERY_STRING} [L]' . "\n" .
- ' RewriteRule ^u/(.*)/(.*).html$ index.php?customers_id=$1&%{QUERY_STRING} [L]' . "\n" .
-
- ' ErrorDocument 401 /' . "\n" .
- ' ErrorDocument 402 /' . "\n" .
- ' ErrorDocument 403 /' . "\n" .
- ' ErrorDocument 404 /' . "\n" .
- ' ErrorDocument 500 /' . "\n" .
- '</IfModule>' . "\n";
-
$fp = fopen($this->fs_document_root . '.htaccess', 'w');
fputs($fp, $file_contents);
fclose($fp);
@@ -511,18 +269,12 @@
private function install_extents(){
$file='includes/tables_files_modules.php';
- $file_contents='<?php' . "\n" .
- '/**' . "\n" .
- ' @licence GPL 2005-'.date('Y').' The osCSS developers - osCSS Open Source E-commerce' . "\n" .
- ' @package oscss-2 <www http://www.oscss.org>' . "\n" .
- ' @date '.date("Y/m/d").'' . "\n" .
- ' @author oscim <mail aur...@os...> <www http://www.oscim.fr>' . "\n" .
- ' @encode UTF-8' . "\n" .
- ' Placer ici Vos definition de table et filename pour les elements modulaire, extensions et plugins.' . "\n" .
- 'ex:' . "\n" .
- ' define(\'TABLE_EPF\', DB_TABLE_PREFIX .\'products_virtual\');' . "\n" .
- '*/' . "\n" .
- '?>';
+ $res=file_get_contents(self::$modele_path.'tables_files_modules.txt');
+
+ $file_contents = '<?php' ."\n";
+ $file_contents .=str_replace(self::$c_k, self::$c_v ,$res);
+ $file_contents .= "\n".'?>';
+
$fp = fopen($this->fs_document_root .$this->ws_admin_rand.'/'.$file, 'w');
fputs($fp, $file_contents);
fclose($fp);
@@ -649,6 +401,9 @@
*/
+
+
+
/**
Email admin
*/
@@ -748,6 +503,9 @@
$this->get_fs_document_root();
$this->get_server_conf();
$this->get_db_conf();
+
+
+
if(file_exists($this->fs_document_root.'admin')) rename($this->fs_document_root.'admin',$this->fs_document_root.$this->ws_admin_rand);
define('TABLE_CONFIGURATION', $this->db['DB_TABLE_PREFIX'].'configuration');
@@ -757,7 +515,9 @@
require($this->fs_document_root.$this->ws_admin_rand.'/includes/functions/lib.configuration.php');
+ $this->AdjustConf();
+
//! ecriture des fichier de conf
$this->install_base_conf();
$this->install_rewrite();
Modified: trunk/catalog/install/includes/content/core.modes.php
===================================================================
--- trunk/catalog/install/includes/content/core.modes.php 2011-10-31 08:02:09 UTC (rev 3851)
+++ trunk/catalog/install/includes/content/core.modes.php 2011-10-31 11:49:06 UTC (rev 3852)
@@ -86,9 +86,9 @@
.'</p>'."\n";
echo '<p class="smallDesc">'."\n"
- .'<label>'.core::l10n('Répertoire de travail:').'</label>'."\n"
- .osc_draw_input_field('HTTP_WORK_DIRECTORY', '', $this->fs_document_root . 'oscss_data')."\n"
- .core::draw_help('httpWork', core::l10n("Ce chemin peut être en dehors du répertoire HTML public, il est même recommandé d'utiliser un répertoire qui ne soit pas accessible par le web. Pour des raisons de sécurité n'utilisez pas le répertoire /tmp/ .")/*, core::l10n('Le chemin du repertoire ou osCSS stockeras ses informations (cache, sessions)')*/)."\n"
+ .'<label>'.core::l10n('Nom du répertoire des dossier inscriptibles:').'</label>'."\n"
+ .osc_draw_input_field('HTTP_WORK_DIRECTORY', '', 'Documents')."\n"
+ .core::draw_help('httpWork', core::l10n("y seront placé tous les fichier est dossier necessaire au fonctionnement.")/*, core::l10n('Le chemin du repertoire ou osCSS stockeras ses informations (cache, sessions)')*/)."\n"
.'</p>'."\n";
echo '<p class="smallDesc">'."\n"
@@ -217,11 +217,11 @@
.'<label>'.core::l10n('Choix de l\'arboresance des dossiers inscriptibles').'</label>'."\n"
.'<ul>'
.'<li>'
- .osc_draw_radio_field('ARBORESANCE', '1', ( (!isset($_POST['ARBORESANCE']) || $_POST['ARBORESANCE'] == '1')? true : false) )."\n" . core::l10n('Classique')
+ .osc_draw_radio_field('ARBORESANCE', '1', 'all',( (!isset($_POST['ARBORESANCE']) || $_POST['ARBORESANCE'] == '1')? true : false) )."\n" . core::l10n('Classique')
.core::draw_help('httpSSL', core::l10n('Un dossier contient l\'ensemble des donnée de l\'application')/*, core::l10n('Activer les connections SSL:')*/)."\n"
.'</li>'
.'<li>'
- .osc_draw_radio_field('ARBORESANCE', '2', ( (isset($_POST['ARBORESANCE'])&& $_POST['ARBORESANCE'] == '2')? true : false) )."\n" . core::l10n('Vhost')
+ .osc_draw_radio_field('ARBORESANCE', '2', 'vhost', ( (isset($_POST['ARBORESANCE'])&& $_POST['ARBORESANCE'] == '2')? true : false) )."\n" . core::l10n('Vhost')
.core::draw_help('httpSSL', core::l10n('Le dossier des données et document est placé au dessus du dossier de l\'application. modificatio du vhost ou acces au dossier superieur')/*, core::l10n('Activer les connections SSL:')*/)."\n"
.'</li>'
.'</ul>'
@@ -297,6 +297,7 @@
Callback
*/
function exe_prev(){
+
}
function draw(){
Added: trunk/catalog/install/includes/modele/admin_configure.txt
===================================================================
--- trunk/catalog/install/includes/modele/admin_configure.txt (rev 0)
+++ trunk/catalog/install/includes/modele/admin_configure.txt 2011-10-31 11:49:06 UTC (rev 3852)
@@ -0,0 +1,118 @@
+ /**
+ @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @package oscss-2 <www http://www.oscss.org>
+ @version %CURRENT_VERSION%
+ @date %CREATE_DATE%
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+ */
+
+ /**
+ * \brief as active / inactive cache and error return
+ * @var boolean default:false
+ */
+ define('OSCSS_DEBUG', %VAR_OSCSS_DEBUG% );
+ /**
+ * \brief as active view query in error requet sql
+ * @var boolean default:false
+ */
+ define('OSCSS_SHOW_QUERIES', true);
+ /**
+ * \brief as active / incative garbage collector error
+ * @var boolean default:true
+ */
+ define('OSCSS_GARBAGE_ERROR', true);
+
+// Define the webserver and path parameters
+// * DIR_FS_* = Filesystem directories (local/physical)
+// * DIR_WS_* = Webserver directories (virtual/URL)
+ define('HTTP_SERVER', '%HTTP_SERVER%'); // eg, http://localhost - should not be empty for productive servers
+ define('HTTPS_SERVER', '%HTTPS_SERVER%'); // eg, https://localhost - should not be empty for productive servers
+ define('HTTP_CATALOG_SERVER', '%HTTP_SERVER%');
+ define('HTTPS_CATALOG_SERVER', '%HTTPS_SERVER%');
+
+ define('ENABLE_SSL', %ENABLE_SSL% );
+ define('ENABLE_SSL_CATALOG', %ENABLE_SSL%); // secure webserver for catalog module
+
+ define('DIR_FS_DOCUMENT_ROOT', '%FS_DOCUMENT_ROOT%'); // where the pages are located on the server
+ define('DIR_FS_ADMIN', '%FS_ADMIN%'); // absolute pate required
+ define('DIR_FS_CATALOG', '%FS_DOCUMENT_ROOT%'); // absolute path required
+ define('DIR_FS_ROOT_DOCS', '%FS_ROOT_DOCS%');
+
+ define('DIR_WS_ADMIN', '%WS_ADMIN%'); // absolute path required
+ define('DIR_WS_CATALOG', '%HTTP_CATALOG%'); // absolute path required
+ define('DIR_WS_HTTP_CATALOG',DIR_WS_CATALOG);// compatibilité SEO
+ define('DIR_WS_HTTPS_CATALOG', '%HTTPS_CATALOG%');
+
+
+ define('DIR_CLASSES', 'classes/');
+ define('DIR_FUNCTIONS', 'functions/');
+ define('DIR_FONTS', 'fonts/');
+ define('DIR_LOGS', 'logs/');
+ define('DIR_CACHE', 'cache/');
+
+ define('DIR_WS_IMAGES', 'images/');
+ define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
+ define('DIR_WS_CATALOG_IMAGES', DIR_WS_CATALOG . 'images/');
+ define('DIR_WS_INCLUDES', 'includes/');
+ define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
+ define('DIR_WS_DOWNLOAD', 'download/');
+
+ define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . DIR_FUNCTIONS);
+ define('DIR_WS_CLASSES', DIR_WS_INCLUDES . DIR_CLASSES);
+ define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
+ define('DIR_WS_LIB', DIR_WS_INCLUDES . 'lib/');
+ define('DIR_WS_PLUGINS', DIR_WS_INCLUDES . 'plugins/');
+ define('DIR_WS_FONTS', DIR_WS_INCLUDES . DIR_FONTS);
+ define('DIR_WS_JS', DIR_WS_INCLUDES . 'javascript/');
+ define('DIR_WS_WIDGET', DIR_WS_INCLUDES . 'widget/');
+ define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
+ define('DIR_WS_CATALOG_LANGUAGES', DIR_WS_CATALOG . 'includes/languages/');
+ define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');
+ define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');
+ define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');
+
+// Documents
+ define('DIR_FS_BACKUP', DIR_FS_ROOT_DOCS . 'admin/backups/');
+ define('DIR_FS_WORK', DIR_FS_ROOT_DOCS . 'admin/public/oscss_data/');
+ define('DIR_FS_SESSIONS', DIR_FS_ROOT_DOCS . 'admin/sessions/');
+ define('DIR_FS_CIP', DIR_FS_ROOT_DOCS . 'admin/contributions/');
+
+// Template System files
+ define('DIR_FS_TEMPLATES', DIR_FS_CATALOG . 'templates/');
+ define('DIR_WS_TEMPLATES', DIR_WS_CATALOG . 'templates/');
+ define('DIR_WS_CATALOG_DOWNLOAD', DIR_WS_CATALOG . 'download/');
+
+// Common
+ define('DIR_WS_COMMON', 'common/');
+ define('DIR_WS_COMMON_FUNCTIONS', DIR_WS_COMMON . DIR_FUNCTIONS);
+ define('DIR_WS_COMMON_FONTS', DIR_WS_COMMON . DIR_FONTS);
+ define('DIR_WS_COMMON_CLASSES', DIR_WS_COMMON . DIR_CLASSES);
+ define('DIR_WS_COMMON_IMAGES', DIR_WS_TEMPLATES . 'layout/');
+
+// define our database connection
+ define('DB_CONNECTOR', '%DBMOTOR%');
+ define('DB_MOTOR', '%DBMOTOR%');
+ define('DB_MOTOR_TYPE', '%DBMOTOR_TYPE%');
+ define('DB_PORT', '%DB_PORT%');
+ define('DB_CHARSET', '%DB_CHARSET%');
+ define('DB_SERVER', '%DB_SERVER%'); // eg, localhost - should not be empty for productive servers
+ define('DB_SERVER_USERNAME', '%DB_SERVER_USERNAME%');
+ define('DB_SERVER_PASSWORD', '%DB_SERVER_PASSWORD%');
+ define('DB_DATABASE', '%DB_DATABASE%');
+ define('DB_TABLE_PREFIX', '%DB_TABLE_PREFIX%');
+ define('USE_PCONNECT', '%USE_PCONNECT%'); // use persisstent connections?
+ define('STORE_SESSIONS', '%STORE_SESSIONS%'); // leave empty '' for default handler or set to 'mysql'
+
+ /**
+ * @brief method login active, separate by ;. the method is call in sort
+ * @example $conf['login']='oscss;openid';
+ * @var $conf->login string
+ */
+ $conf['login']='oscss;';
+
+ /**
+ @var Security key
+ @brief use by offline mode
+ */
+ $SecuKey='%SECURE_KEY%';
Added: trunk/catalog/install/includes/modele/admin_htaccess.txt
===================================================================
--- trunk/catalog/install/includes/modele/admin_htaccess.txt (rev 0)
+++ trunk/catalog/install/includes/modele/admin_htaccess.txt 2011-10-31 11:49:06 UTC (rev 3852)
@@ -0,0 +1,83 @@
+# licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+# package oscss-2 <www http://www.oscss.org>
+# version %CURRENT_VERSION%
+# date %CREATE_DATE%
+# author oscim <mail aur...@os...> <www http://www.oscim.fr>
+# encode UTF-8
+# Default OsCss Htaccess
+
+
+
+# <Directory "/usr/local/apache/htdocs">
+# AllowOverride Options
+# </Directory>
+# The following makes adjustments to the SSL protocol for Internet
+# Explorer browsers
+# <IfModule mod_setenvif.c>
+# <IfDefine SSL>
+# SetEnvIf User-Agent ".*MSIE.*" \
+# nokeepalive ssl-unclean-shutdown \
+# downgrade-1.0 force-response-1.0
+# </IfDefine>
+# </IfModule>
+
+
+
+# Fix certain PHP values
+## element pur hebergement mutulalise, a commenter si inutile
+ SetEnv REGISTER_GLOBALS 0
+ SetEnv MAGIC_QUOTES 1
+ SetEnv PHP_VER 5
+
+# force default charset
+ AddDefaultCharset UTF-8
+
+# FIX
+<IfModule mod_php5.c>
+ php_flag register_long_arrays Off
+ php_value register_globals off
+</IfModule>
+
+<IfModule mod_rewrite.c>
+
+# 404 error
+ ErrorDocument 404 /404.php
+
+ RewriteEngine on
+ RewriteBase %WS_ADMIN%
+
+ RewriteCond %{QUERY_STRING} (\<|%3C).*script.*(\>|%3E) [NC,OR]
+ RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]
+ RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})
+ RewriteRule ^(.*)$ index.php [F,L]
+
+ RewriteRule (.*cronfile\.ph.*)$ $1 [L]
+
+ RewriteCond %{QUERY_STRING} (\<|%3C).*script.*(\>|%3E) [NC,OR]
+ RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]
+ RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2})
+ RewriteRule ^(.*)$ index.php [F,L]
+ RewriteRule ^$ index.php?page_admin=index [L]
+ RewriteRule ^rss.php rss.php?%{QUERY_STRING} [L]
+
+ RewriteRule ^attributeManager/attributeManager/(.*)$ attributeManager/$1 [L]
+ RewriteRule ^(attributeManager/.*)$ $1 [L]
+ RewriteRule (.*plugins/.*)$ $1 [L]
+ RewriteRule (.*editeur/.*)$ $1 [L]
+ RewriteRule (.*template/.*)$ $1 [L]
+ RewriteRule (.*images/.*)$ $1 [L]
+ RewriteRule (.*includes/.*)$ $1 [L]
+ RewriteRule (.*\.css)$ $1[L]
+ RewriteRule (.*logoff\.ph.*)$ $1 [L]
+ RewriteRule (.*login\.ph.*)$ $1 [L]
+ RewriteRule (.*document\.ph.*)$ $1 [L]
+ RewriteRule (.*password_forgotten\.ph.*)$ $1 [L]
+ RewriteRule (.*popup_image\.ph.*)$ $1 [L]
+ RewriteRule (.*login\.ph.*)$ $1 [L]
+ RewriteRule ([0-9A-Za-z_&=-]*)(.php)?(.*)$ index.php?page_admin=$1&%{QUERY_STRING} [L]
+ ErrorDocument 401 /
+ ErrorDocument 402 /
+ ErrorDocument 403 /
+ ErrorDocument 404 /
+ ErrorDocument 500 /
+</IfModule>
Added: trunk/catalog/install/includes/modele/configure.txt
===================================================================
--- trunk/catalog/install/includes/modele/configure.txt (rev 0)
+++ trunk/catalog/install/includes/modele/configure.txt 2011-10-31 11:49:06 UTC (rev 3852)
@@ -0,0 +1,101 @@
+/**
+ @licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+ @package oscss-2 <www http://www.oscss.org>
+ @version %CURRENT_VERSION%
+ @date %CREATE_DATE%
+ @author oscim <mail aur...@os...> <www http://www.oscim.fr>
+ @encode UTF-8
+*/
+
+ /**
+ * \brief as active / inactive cache and error return
+ * @var boolean default:false
+ */
+ define('OSCSS_DEBUG', true);
+ /**
+ * \brief as active view query in error requet sql
+ * @var boolean default:false
+ */
+ define('OSCSS_SHOW_QUERIES', true);
+ /**
+ * \brief as active / incative garbage collector error
+ * @var boolean default: true
+ */
+ define('OSCSS_GARBAGE_ERROR', true);
+
+// Define the webserver and path parameters
+// * DIR_FS_* = Filesystem directories (local/physical)
+// * DIR_WS_* = Webserver directories (virtual/URL)
+
+ define('HTTP_SERVER', '%HTTP_SERVER%'); // eg, http://localhost - should not be empty for productive servers
+ define('HTTPS_SERVER', '%HTTPS_SERVER%'); // eg, https://localhost - should not be empty for productive servers
+ define('ENABLE_SSL', %ENABLE_SSL%); // secure webserver for checkout procedure?
+ define('HTTP_COOKIE_DOMAIN', '%HTTP_COOKIE_DOMAIN%');
+ define('HTTPS_COOKIE_DOMAIN', '%HTTPS_COOKIE_DOMAIN%');
+ define('HTTP_COOKIE_PATH', '%HTTP_COOKIE_PATH%');
+ define('HTTPS_COOKIE_PATH', '%HTTPS_COOKIE_PATH%');
+ define('DIR_WS_HTTP_CATALOG', '%HTTP_SERVER%');
+ define('DIR_WS_HTTPS_CATALOG', '%HTTPS_SERVER%');
+
+ define('DIR_CLASSES', 'classes/');
+ define('DIR_FUNCTIONS', 'functions/');
+ define('DIR_FONTS', 'fonts/');
+
+
+ define('DIR_WS_IMAGES', 'images/');
+ define('DIR_WS_ICONS', DIR_WS_IMAGES . 'icons/');
+ define('DIR_WS_INCLUDES', 'includes/');
+ define('DIR_WS_BOXES', DIR_WS_INCLUDES . 'boxes/');
+ define('DIR_WS_FUNCTIONS', DIR_WS_INCLUDES . DIR_FUNCTIONS);
+ define('DIR_WS_CLASSES', DIR_WS_INCLUDES . DIR_CLASSES);
+ define('DIR_WS_MODULES', DIR_WS_INCLUDES . 'modules/');
+ define('DIR_WS_LANGUAGES', DIR_WS_INCLUDES . 'languages/');
+ define('DIR_WS_TRIGGERS', DIR_WS_INCLUDES . 'triggers/');
+ define('DIR_WS_DOWNLOAD_PUBLIC', 'pub/');
+
+ define('DIR_FS_CATALOG', '%FS_DOCUMENT_ROOT%');
+ define('DIR_FS_ROOT_DOCS', '%FS_DOCUMENT_ROOT%/Documents/');
+
+ define('DIR_FS_CATALOG_IMAGES', DIR_FS_CATALOG . 'images/');
+ define('DIR_FS_CATALOG_MODULES', DIR_FS_CATALOG . 'includes/modules/');
+ define('DIR_FS_CATALOG_LANGUAGES', DIR_FS_CATALOG . 'includes/languages/');
+ define('DIR_FS_CATALOG_TEMPLATE', DIR_FS_CATALOG . 'templates/');
+
+// public docs
+ define('DIR_FS_DOWNLOAD', DIR_FS_CATALOG . 'download/');
+ define('DIR_FS_DOWNLOAD_PUBLIC', DIR_FS_CATALOG . 'pub/');
+
+// Documents
+ define('DIR_FS_SESSIONS', DIR_FS_ROOT_DOCS . 'public/sessions/');
+ define('DIR_FS_WORK', DIR_FS_ROOT_DOCS . 'public/oscss_data/');
+
+// Template System files
+ define('DIR_FS_TEMPLATES', DIR_FS_CATALOG . 'templates/');
+ define('DIR_WS_TEMPLATES', 'templates/');
+
+// Common
+ define('DIR_WS_COMMON', 'common/');
+ define('DIR_WS_COMMON_FUNCTIONS', DIR_WS_COMMON . DIR_FUNCTIONS);
+ define('DIR_WS_COMMON_FONTS', DIR_WS_COMMON . DIR_FONTS);
+ define('DIR_WS_COMMON_CLASSES', DIR_WS_COMMON . DIR_CLASSES);
+ define('DIR_WS_COMMON_IMAGES', DIR_WS_TEMPLATES . 'layout/');
+
+// define our database connection
+ define('DB_CONNECTOR', '%DBMOTOR%');
+ define('DB_MOTOR', '%DBMOTOR%');
+ define('DB_MOTOR_TYPE', '%DBMOTOR_TYPE%');
+ define('DB_PORT', '%DB_PORT%');
+ define('DB_CHARSET', '%DB_CHARSET%');
+ define('DB_SERVER', '%DB_SERVER%'); // eg, localhost - should not be empty for productive servers
+ define('DB_SERVER_USERNAME', '%DB_SERVER_USERNAME%');
+ define('DB_SERVER_PASSWORD', '%DB_SERVER_PASSWORD%');
+ define('DB_DATABASE', '%DB_DATABASE%');
+ define('DB_TABLE_PREFIX', '%DB_TABLE_PREFIX%');
+ define('USE_PCONNECT', '%USE_PCONNECT%'); // use persisstent connections?
+ define('STORE_SESSIONS', '%STORE_SESSIONS%'); // leave empty '' for default handler or set to 'mysql'
+
+ /**
+ @var Security key
+ @brief use by offline mode
+ */
+ $SecuKey='%SECURE_KEY%';
\ No newline at end of file
Added: trunk/catalog/install/includes/modele/htaccess.txt
===================================================================
--- trunk/catalog/install/includes/modele/htaccess.txt (rev 0)
+++ trunk/catalog/install/includes/modele/htaccess.txt 2011-10-31 11:49:06 UTC (rev 3852)
@@ -0,0 +1,125 @@
+# licence GPL 2005-2010 The osCSS developers - osCSS Open Source E-commerce
+# package oscss-2 <www http://www.oscss.org>
+# version %CURRENT_VERSION%
+# date %CREATE_DATE%
+# author oscim <mail aur...@os...> <www http://www.oscim.fr>
+# encode UTF-8
+# Default OsCss Htaccess
+
+
+
+# <Directory "/usr/local/apache/htdocs">
+# AllowOverride Options
+# </Directory>
+# The following makes adjustments to the SSL protocol for Internet
+# Explorer browsers
+# <IfModule mod_setenvif.c>
+# <IfDefine SSL>
+# SetEnvIf User-Agent ".*MSIE.*" \
+# nokeepalive ssl-unclean-shutdown \
+# downgrade-1.0 force-response-1.0
+# </IfDefine>
+# </IfModule>
+
+
+
+# Fix certain PHP values
+## element pur hebergement mutulalise, a commenter si inutile
+ SetEnv REGISTER_GLOBALS 0
+ SetEnv MAGIC_QUOTES 1
+ SetEnv PHP_VER 5
+
+# force default charset
+ AddDefaultCharset UTF-8
+
+# FIX
+<IfModule mod_php5.c>
+ php_flag register_long_arrays Off
+ php_value register_globals off
+</IfModule>
+
+<IfModule mod_rewrite.c>
+
+# 404 error
+ ErrorDocument 404 /404.php
+
+ RewriteEngine on
+ RewriteBase %WS_DOCUMENT_ROOT%
+
+ RewriteCond %{QUERY_STRING} (\<|%3C).*script.*(\>|%3E) [NC,OR]
+ RewriteCond %{QUERY_STRING} GLOBALS(=|\[|\%[0-9A-Z]{0,2}) [OR]
+ RewriteCond %{QUERY_STRING} _REQUEST(=|\[|\%[0-9A-Z]{0,2}...
[truncated message content] |