diff --git a/htdocs/barcode/codeinit.php b/htdocs/barcode/codeinit.php index 806a88325fb..26386052480 100644 --- a/htdocs/barcode/codeinit.php +++ b/htdocs/barcode/codeinit.php @@ -25,10 +25,8 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/societe/class/societe.class.php'; require_once DOL_DOCUMENT_ROOT.'/product/class/product.class.php'; -$langs->load("admin"); -$langs->load("members"); -$langs->load("errors"); -$langs->load("other"); +// Load translation files required by the page +$langs->loadLangs(array('admin', 'members', 'errors', 'other')); // Choice of print year or current year. $now = dol_now(); diff --git a/htdocs/barcode/printsheet.php b/htdocs/barcode/printsheet.php index 04a181d3613..7dfec76b39e 100644 --- a/htdocs/barcode/printsheet.php +++ b/htdocs/barcode/printsheet.php @@ -28,9 +28,8 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/modules/printsheet/modules_labels.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/genericobject.class.php'; -$langs->load("admin"); -$langs->load("members"); -$langs->load("errors"); +// Load translation files required by the page +$langs->loadLangs(array('admin', 'members', 'errors')); // Choice of print year or current year. $now = dol_now(); diff --git a/htdocs/blockedlog/admin/blockedlog.php b/htdocs/blockedlog/admin/blockedlog.php index e4b38a9568f..326fea79c5d 100644 --- a/htdocs/blockedlog/admin/blockedlog.php +++ b/htdocs/blockedlog/admin/blockedlog.php @@ -27,6 +27,7 @@ require_once DOL_DOCUMENT_ROOT.'/blockedlog/lib/blockedlog.lib.php'; require_once DOL_DOCUMENT_ROOT.'/blockedlog/class/blockedlog.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php'; +// Load translation files required by the page $langs->loadLangs(array("admin","other","blockedlog")); if (! $user->admin || empty($conf->blockedlog->enabled)) accessforbidden(); diff --git a/htdocs/blockedlog/admin/blockedlog_list.php b/htdocs/blockedlog/admin/blockedlog_list.php index e8b2dc8b73b..dbb0affdbdf 100644 --- a/htdocs/blockedlog/admin/blockedlog_list.php +++ b/htdocs/blockedlog/admin/blockedlog_list.php @@ -29,6 +29,7 @@ require_once DOL_DOCUMENT_ROOT.'/blockedlog/class/authority.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php'; +// Load translation files required by the page $langs->loadLangs(array("admin", "other", "blockedlog", "bills")); if ((! $user->admin && ! $user->rights->blockedlog->read) || empty($conf->blockedlog->enabled)) accessforbidden(); diff --git a/htdocs/blockedlog/ajax/index.html b/htdocs/blockedlog/ajax/index.html new file mode 100644 index 00000000000..e69de29bb2d diff --git a/htdocs/blockedlog/class/index.html b/htdocs/blockedlog/class/index.html new file mode 100644 index 00000000000..e69de29bb2d diff --git a/htdocs/blockedlog/index.html b/htdocs/blockedlog/index.html new file mode 100644 index 00000000000..e69de29bb2d diff --git a/htdocs/bookmarks/admin/bookmark.php b/htdocs/bookmarks/admin/bookmark.php index 709fadc6301..25fa032902f 100644 --- a/htdocs/bookmarks/admin/bookmark.php +++ b/htdocs/bookmarks/admin/bookmark.php @@ -25,6 +25,7 @@ require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/admin.lib.php'; +// Load translation files required by the page $langs->load("admin"); if (!$user->admin) diff --git a/htdocs/bookmarks/card.php b/htdocs/bookmarks/card.php index 54512a8049e..d450e476506 100644 --- a/htdocs/bookmarks/card.php +++ b/htdocs/bookmarks/card.php @@ -27,8 +27,8 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/bookmarks/class/bookmark.class.php'; -$langs->load("bookmarks"); -$langs->load("other"); +// Load translation files required by the page +$langs->loadLangs(array('bookmarks', 'other')); // Security check if (! $user->rights->bookmark->lire) { diff --git a/htdocs/bookmarks/list.php b/htdocs/bookmarks/list.php index fa46f683e50..f96eb50c531 100644 --- a/htdocs/bookmarks/list.php +++ b/htdocs/bookmarks/list.php @@ -24,8 +24,8 @@ require '../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/bookmarks/class/bookmark.class.php'; -$langs->load("bookmarks"); -$langs->load("admin"); +// Load translation files required by the page +$langs->loadLangs(array('bookmarks', 'admin')); $action=GETPOST('action','alpha'); $massaction=GETPOST('massaction','alpha'); diff --git a/htdocs/categories/admin/categorie.php b/htdocs/categories/admin/categorie.php index e0c51803faf..92e23a2199a 100644 --- a/htdocs/categories/admin/categorie.php +++ b/htdocs/categories/admin/categorie.php @@ -30,6 +30,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/categories.lib.php'; if (!$user->admin) accessforbidden(); +// Load translation files required by the page $langs->load("categories"); $action=GETPOST('action','aZ09'); @@ -122,4 +123,4 @@ print ''; print ''; llxFooter(); -$db->close(); \ No newline at end of file +$db->close(); diff --git a/htdocs/categories/admin/categorie_extrafields.php b/htdocs/categories/admin/categorie_extrafields.php index 3e5a252264f..3fd7d1c69b5 100644 --- a/htdocs/categories/admin/categorie_extrafields.php +++ b/htdocs/categories/admin/categorie_extrafields.php @@ -28,8 +28,8 @@ require '../../main.inc.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/categories.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php'; -$langs->load("categories"); -$langs->load("admin"); +// Load translation files required by the page +$langs->loadLangs(array('categories', 'admin')); $extrafields = new ExtraFields($db); $form = new Form($db); diff --git a/htdocs/categories/card.php b/htdocs/categories/card.php index 60689dd37aa..db56902347b 100644 --- a/htdocs/categories/card.php +++ b/htdocs/categories/card.php @@ -31,6 +31,7 @@ require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php'; +// Load translation files required by the page $langs->load("categories"); // Security check diff --git a/htdocs/categories/edit.php b/htdocs/categories/edit.php index 67190aee2e2..b420847f6fd 100644 --- a/htdocs/categories/edit.php +++ b/htdocs/categories/edit.php @@ -29,6 +29,7 @@ require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php'; +// Load translation files required by the page $langs->load("categories"); $id=GETPOST('id','int'); diff --git a/htdocs/categories/index.php b/htdocs/categories/index.php index 88dea3ea761..e57e51caf62 100644 --- a/htdocs/categories/index.php +++ b/htdocs/categories/index.php @@ -31,6 +31,7 @@ require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/treeview.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/functions2.lib.php'; +// Load translation files required by the page $langs->load("categories"); if (! $user->rights->categorie->lire) accessforbidden(); diff --git a/htdocs/categories/photos.php b/htdocs/categories/photos.php index e6047ed2149..472a8eb9b95 100644 --- a/htdocs/categories/photos.php +++ b/htdocs/categories/photos.php @@ -32,8 +32,8 @@ require_once DOL_DOCUMENT_ROOT.'/core/class/html.formfile.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/lib/categories.lib.php'; -$langs->load("categories"); -$langs->load("bills"); +// Load translation files required by the page +$langs->loadlangs(array('categories', 'bills')); $id=GETPOST('id','int'); diff --git a/htdocs/categories/traduction.php b/htdocs/categories/traduction.php index 40b40eab921..7d71b43a81b 100644 --- a/htdocs/categories/traduction.php +++ b/htdocs/categories/traduction.php @@ -32,8 +32,8 @@ require_once DOL_DOCUMENT_ROOT.'/categories/class/categorie.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formadmin.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php'; -$langs->load("categories"); -$langs->load("languages"); +// Load translation files required by the page +$langs->loadLangs(array('categories', 'languages')); $id = GETPOST('id', 'int'); $ref = GETPOST('ref', 'alpha'); diff --git a/htdocs/categories/viewcat.php b/htdocs/categories/viewcat.php index 825abfc5fe5..24e70e7d587 100644 --- a/htdocs/categories/viewcat.php +++ b/htdocs/categories/viewcat.php @@ -31,7 +31,7 @@ require_once DOL_DOCUMENT_ROOT.'/core/lib/categories.lib.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/extrafields.class.php'; require_once DOL_DOCUMENT_ROOT.'/core/class/html.formother.class.php'; - +// Load translation files required by the page $langs->load("categories"); $id = GETPOST('id','int');