From 98ca403ec99c0dee51470d664bc6c7a76dcafe75 Mon Sep 17 00:00:00 2001 From: Moc Date: Sun, 26 May 2013 16:01:01 -0700 Subject: [PATCH] Edited examples on how to include plugin language files --- e107-Coding-Standard.md | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/e107-Coding-Standard.md b/e107-Coding-Standard.md index 10a602c..8c599c9 100644 --- a/e107-Coding-Standard.md +++ b/e107-Coding-Standard.md @@ -308,9 +308,19 @@ To load a language file from the current theme's directory: e107::lan('theme'); // loads e107_themes/CURRENT_THEME/languages/English.php (when English is selected) To load a language file from a plugin folder: + + e107::lan('faqs'); + e107::lan('faqs',true); + e107::lan('faqs',false, true); + e107::lan('faqs',true, true); + +Will include the following paths: + + e107_plugins/faqs/languages/English_front.php + e107_plugins/faqs/languages/English_admin.php + e107_plugins/faqs/languages/English/English_front.php + e107_plugins/faqs/languages/English/English_admin.php - e107::lan('gallery'); // loads e107_plugins/gallery/languages/English/English_front.php (when English is selected) - e107::lan('gallery',true); // loads e107_plugins/gallery/languages/English/English_admin.php (when English is selected) ### Defining Language Terms aka 'LANS'