diff --git a/notes/trunk/class/class_modules_tools.php b/notes/trunk/class/class_modules_tools.php index 072ba5629ebb499a8e00d9636af1c37abf5be72b..6b1665ac19b7bd71b27b1421adebe575bbe2212a 100644 --- a/notes/trunk/class/class_modules_tools.php +++ b/notes/trunk/class/class_modules_tools.php @@ -20,7 +20,7 @@ class notes */ public function build_modules_tables() { - $xmlconfig = simplexml_load_file($_SESSION['pathtomodules']."notes/xml/config.xml"); + $xmlconfig = simplexml_load_file("modules/notes/xml/config.xml"); foreach($xmlconfig->TABLENAME as $TABLENAME) { $_SESSION['tablename']['not_notes'] = (string) $TABLENAME->not_notes; @@ -36,4 +36,4 @@ class notes } } -?> \ No newline at end of file +?> diff --git a/notes/trunk/frame_notes_doc.php b/notes/trunk/frame_notes_doc.php index 410f9967b6207a77d5efde7cc300fce1be68c43f..07380b0bb0bcfe7678c1cdc54df51c9d80db3945 100644 --- a/notes/trunk/frame_notes_doc.php +++ b/notes/trunk/frame_notes_doc.php @@ -9,15 +9,15 @@ * @license GPL * @author Claire Figueras <dev@maarch.org> */ -session_name('PeopleBox'); -session_start(); -require_once($_SESSION['pathtocoreclass']."class_functions.php"); -require_once($_SESSION['pathtocoreclass']."class_core_tools.php"); +include('core/init.php'); + +require_once("core/class/class_functions.php"); +require_once("core/class/class_core_tools.php"); $core_tools = new core_tools(); //here we loading the lang vars $core_tools->load_lang(); $core_tools->test_service('manage_notes_doc', 'notes'); -require_once($_SESSION['pathtocoreclass']."class_db.php"); +require_once("core/class/class_db.php"); $func = new functions(); //$db = new dbquery(); //$db->connect(); @@ -27,7 +27,7 @@ if(empty($_SESSION['collection_id_choice'])) } //$db->query("select i.id, i.note_text, i.date, i.user_id, u.lastname, u.firstname from ".$_SESSION['tablename']['not_notes']." i //inner join ".$_SESSION['tablename']['users']." u on i.user_id = u.user_id WHERE identifier = ".$_SESSION['doc_id']." and i.coll_id = '".$_SESSION['collection_id_choice']."' ORDER BY date desc"); -require_once($_SESSION['pathtocoreclass']."class_request.php"); +require_once("core/class/class_request.php"); require_once($_SESSION['config']['businessapppath']."class".DIRECTORY_SEPARATOR."class_list_show.php"); $func = new functions(); $select[$_SESSION['tablename']['users']] = array(); diff --git a/notes/trunk/lang/en.php b/notes/trunk/lang/en.php index df758e9cf11d1e63abe957fec6aa82ce192a51e4..95141a6f6c132705ac9c31a65b2efe3b40a6bb5c 100644 --- a/notes/trunk/lang/en.php +++ b/notes/trunk/lang/en.php @@ -25,7 +25,10 @@ define('_ADDITION_NOTE', 'Add a note'); define('_NOTES_DELETED', 'Note deleted'); define('_NOTES_MODIFIED', 'Note modified'); define('_NOTE_UPDATED', 'Note modified'); -define('_NOTES', 'Notes'); +if(!defined('_NOTES')) +{ + define('_NOTES', 'Notes'); +} define('_NOTES_COMMENT', 'Notes'); define('_OF', 'of'); diff --git a/notes/trunk/lang/fr.php b/notes/trunk/lang/fr.php index 2c297e5b92ac4eeca639f6e930d9afbc94c33af6..cb1e2617325bcb8b8f41f13576cc2cea5c50a917 100644 --- a/notes/trunk/lang/fr.php +++ b/notes/trunk/lang/fr.php @@ -25,7 +25,10 @@ define('_ADDITION_NOTE', 'Ajout d’une note'); define('_NOTES_DELETED', 'Note supprimée'); define('_NOTES_MODIFIED', 'Note modifiée'); define('_NOTE_UPDATED', 'Note modifiée'); -define('_NOTES', 'Notes'); +if(!defined('_NOTES')) +{ + define('_NOTES', 'Notes'); +} define('_NOTES_COMMENT', 'Notes'); define('_OF', 'de'); ?> diff --git a/notes/trunk/note_add.php b/notes/trunk/note_add.php index 1f834bdc0a708a848b590e95ec3236407c88ca12..694cd6195cafb0b5d8e64fb568e6f57a5ed83c45 100644 --- a/notes/trunk/note_add.php +++ b/notes/trunk/note_add.php @@ -10,13 +10,13 @@ * @license GPL * @author Claire Figueras <dev@maarch.org> */ -session_name('PeopleBox'); -session_start(); +include('core/init.php'); -require_once($_SESSION['pathtocoreclass']."class_functions.php"); -require_once($_SESSION['pathtocoreclass']."class_db.php"); -require_once($_SESSION['pathtocoreclass']."class_core_tools.php"); -require_once($_SESSION['pathtocoreclass']."class_security.php"); + +require_once("core/class/class_functions.php"); +require_once("core/class/class_db.php"); +require_once("core/class/class_core_tools.php"); +require_once("core/class/class_security.php"); $core_tools = new core_tools(); $sec = new security(); @@ -66,7 +66,7 @@ if (isset($_REQUEST['notes'])&& !empty($_REQUEST['notes'])) if($_SESSION['history']['noteadd']) { - require_once($_SESSION['pathtocoreclass']."class_history.php"); + require_once("core/class/class_history.php"); $hist = new history(); $hist->add($view, $identifier ,"ADD", _ADDITION_NOTE._ON_DOC_NUM.$identifier, $_SESSION['config']['databasetype'], 'notes'); diff --git a/notes/trunk/note_details.php b/notes/trunk/note_details.php index 301036bcaf350ef0a75b1509eb6525b4b8df96a2..f9967c2c4dbb1f5d203a4fe0b419f3d4b3f482d8 100644 --- a/notes/trunk/note_details.php +++ b/notes/trunk/note_details.php @@ -10,17 +10,17 @@ * @license GPL * @author Claire Figueras <dev@maarch.org> */ -session_name('PeopleBox'); -session_start(); +include('core/init.php'); + -require_once($_SESSION['pathtocoreclass']."class_functions.php"); -require($_SESSION['pathtocoreclass']."class_core_tools.php"); +require_once("core/class/class_functions.php"); +require("core/class/class_core_tools.php"); $core_tools = new core_tools(); //here we loading the lang vars $core_tools->load_lang(); -require_once($_SESSION['pathtocoreclass']."class_db.php"); +require_once("core/class/class_db.php"); $func = new functions(); $db = new dbquery(); @@ -55,7 +55,7 @@ if(isset($_REQUEST['modify']) ) if($_SESSION['history']['noteup']) { - require_once($_SESSION['pathtocoreclass']."class_history.php"); + require_once("core/class/class_history.php"); $hist = new history(); $hist->add($_SESSION['tablename']['not_notes'], $id ,"UP", _NOTE_UPDATED, $_SESSION['config']['databasetype'], 'notes'); } @@ -75,7 +75,7 @@ if(isset($_REQUEST['delete']) ) if($_SESSION['history']['notedel']) { - require_once($_SESSION['pathtocoreclass']."class_history.php"); + require_once("core/class/class_history.php"); $hist = new history(); $hist->add($_SESSION['tablename']['not_notes'], $id ,"DEL", _NOTES_DELETED, $_SESSION['config']['databasetype'], 'notes'); } diff --git a/notes/trunk/notes_doc.php b/notes/trunk/notes_doc.php index 64c908b881fd5e6191b76a67e8616e771016826d..11675a0538c99196753a823d1164addb53fbaf3a 100644 --- a/notes/trunk/notes_doc.php +++ b/notes/trunk/notes_doc.php @@ -9,10 +9,10 @@ * @license GPL * @author Claire Figueras <dev@maarch.org> */ -session_name('PeopleBox'); -session_start(); -require_once($_SESSION['pathtocoreclass']."class_functions.php"); -require_once($_SESSION['pathtocoreclass']."class_core_tools.php"); +include('core/init.php'); + +require_once("core/class/class_functions.php"); +require_once("core/class/class_core_tools.php"); $core_tools = new core_tools(); //here we loading the lang vars $core_tools->load_lang(); diff --git a/notes/trunk/show_notes_list.php b/notes/trunk/show_notes_list.php index 40065b00e5d293a1dcadb4723ef75c02e5fbe14a..48b14ac7ecce3ae7083184b33b82c6457d21c2b9 100644 --- a/notes/trunk/show_notes_list.php +++ b/notes/trunk/show_notes_list.php @@ -9,17 +9,17 @@ * @license GPL * @author Loïc Vinet <dev@maarch.org> */ -session_name('PeopleBox'); -session_start(); -require_once($_SESSION['pathtocoreclass']."class_functions.php"); -require_once($_SESSION['pathtocoreclass']."class_core_tools.php"); +include('core/init.php'); + +require_once("core/class/class_functions.php"); +require_once("core/class/class_core_tools.php"); $core_tools = new core_tools(); //here we loading the lang vars $core_tools->load_lang(); $core_tools->test_service('show_notes_list', 'notes'); -require_once($_SESSION['pathtocoreclass']."class_db.php"); +require_once("core/class/class_db.php"); $func = new functions(); if(empty($_SESSION['collection_id_choice'])) @@ -27,7 +27,7 @@ if(empty($_SESSION['collection_id_choice'])) $_SESSION['collection_id_choice']= $_SESSION['user']['collections'][0]; } -require_once($_SESSION['pathtocoreclass']."class_request.php"); +require_once("core/class/class_request.php"); require_once($_SESSION['config']['businessapppath']."class".DIRECTORY_SEPARATOR."class_list_show.php"); /*